@daostack/upgrades
Version:
Proxy upgadable contracts based on openzeppelin-sdk
28,000 lines • 1.14 MB
JSON
{
"fileName": "MockStandaloneERC721.sol",
"contractName": "IMockERC721Enumerable",
"source": "pragma solidity ^0.6.0;\n// SPDX-License-Identifier: MIT\n\nimport \"../Initializable.sol\";\n\n// File: contracts/introspection/IERC165.sol\n\n/**\n * @title IERC165\n * @dev https://github.com/ethereum/EIPs/blob/master/EIPS/eip-165.md\n */\ninterface IERC165 {\n /**\n * @notice Query if a contract implements an interface\n * @param interfaceId The interface identifier, as specified in ERC-165\n * @dev Interface identification is specified in ERC-165. This function\n * uses less than 30,000 gas.\n */\n function supportsInterface(bytes4 interfaceId) external view returns (bool);\n}\n\n// File: contracts/token/MockERC721/IMockERC721.sol\n\n\n\n/**\n * @title MockERC721 Non-Fungible Token Standard basic interface\n * @dev see https://github.com/ethereum/EIPs/blob/master/EIPS/eip-721.md\n */\nabstract contract IMockERC721 is Initializable, IERC165 {\n event Transfer(address indexed from, address indexed to, uint256 indexed tokenId);\n event Approval(address indexed owner, address indexed approved, uint256 indexed tokenId);\n event ApprovalForAll(address indexed owner, address indexed operator, bool approved);\n\n // function balanceOf(address owner) public view virtual returns (uint256 balance);\n // function ownerOf(uint256 tokenId) public view virtual returns (address owner);\n //\n // function approve(address to, uint256 tokenId) public virtual;\n // function getApproved(uint256 tokenId) public view virtual returns (address operator);\n //\n // function setApprovalForAll(address operator, bool _approved) public virtual;\n // function isApprovedForAll(address owner, address operator) public view virtual returns (bool) ;\n //\n // function transferFrom(address from, address to, uint256 tokenId) public virtual;\n // function safeTransferFrom(address from, address to, uint256 tokenId) public virtual;\n //\n // function safeTransferFrom(address from, address to, uint256 tokenId, bytes memory data) public virtual;\n}\n\n// File: contracts/token/MockERC721/IMockERC721Receiver.sol\n\n/**\n * @title MockERC721 token receiver interface\n * @dev Interface for any contract that wants to support safeTransfers\n * from MockERC721 asset contracts.\n */\nabstract contract IMockERC721Receiver {\n /**\n * @notice Handle the receipt of an NFT\n * @dev The MockERC721 smart contract calls this function on the recipient\n * after a `safeTransfer`. This function MUST return the function selector,\n * otherwise the caller will revert the transaction. The selector to be\n * returned can be obtained as `this.onMockERC721Received.selector`. This\n * function MAY throw to revert and reject the transfer.\n * Note: the MockERC721 contract address is always the message sender.\n * @param operator The address which called `safeTransferFrom` function\n * @param from The address which previously owned the token\n * @param tokenId The NFT identifier which is being transferred\n * @param data Additional data with no specified format\n * @return `bytes4(keccak256(\"onMockERC721Received(address,address,uint256,bytes)\"))`\n */\n function onMockERC721Received(address operator, address from, uint256 tokenId, bytes memory data)\n public virtual returns (bytes4);\n}\n\n// File: contracts/math/SafeMath.sol\n\n/**\n * @title SafeMath\n * @dev Unsigned math operations with safety checks that revert on error\n */\nlibrary SafeMath {\n /**\n * @dev Multiplies two unsigned integers, reverts on overflow.\n */\n function mul(uint256 a, uint256 b) internal pure returns (uint256) {\n // Gas optimization: this is cheaper than requiring 'a' not being zero, but the\n // benefit is lost if 'b' is also tested.\n // See: https://github.com/OpenZeppelin/openzeppelin-solidity/pull/522\n if (a == 0) {\n return 0;\n }\n\n uint256 c = a * b;\n require(c / a == b);\n\n return c;\n }\n\n /**\n * @dev Integer division of two unsigned integers truncating the quotient, reverts on division by zero.\n */\n function div(uint256 a, uint256 b) internal pure returns (uint256) {\n // Solidity only automatically asserts when dividing by 0\n require(b > 0);\n uint256 c = a / b;\n // assert(a == b * c + a % b); // There is no case in which this doesn't hold\n\n return c;\n }\n\n /**\n * @dev Subtracts two unsigned integers, reverts on overflow (i.e. if subtrahend is greater than minuend).\n */\n function sub(uint256 a, uint256 b) internal pure returns (uint256) {\n require(b <= a);\n uint256 c = a - b;\n\n return c;\n }\n\n /**\n * @dev Adds two unsigned integers, reverts on overflow.\n */\n function add(uint256 a, uint256 b) internal pure returns (uint256) {\n uint256 c = a + b;\n require(c >= a);\n\n return c;\n }\n\n /**\n * @dev Divides two unsigned integers and returns the remainder (unsigned integer modulo),\n * reverts when dividing by zero.\n */\n function mod(uint256 a, uint256 b) internal pure returns (uint256) {\n require(b != 0);\n return a % b;\n }\n}\n\n// File: contracts/utils/Address.sol\n\n/**\n * Utility library of inline functions on addresses\n */\nlibrary Address {\n /**\n * Returns whether the target address is a contract\n * @dev This function will return false if invoked during the constructor of a contract,\n * as the code is not actually created until after the constructor finishes.\n * @param account address of the account to check\n * @return whether the target address is a contract\n */\n function isContract(address account) internal view returns (bool) {\n uint256 size;\n // XXX Currently there is no better way to check if there is a contract in an address\n // than to check the size of the code at that address.\n // See https://ethereum.stackexchange.com/a/14016/36603\n // for more details about how this works.\n // TODO Check this again before the Serenity release, because all addresses will be\n // contracts then.\n // solhint-disable-next-line no-inline-assembly\n assembly { size := extcodesize(account) }\n return size > 0;\n }\n}\n\n// File: contracts/introspection/ERC165.sol\n\n\n\n/**\n * @title ERC165\n * @author Matt Condon (@shrugs)\n * @dev Implements ERC165 using a lookup table.\n */\ncontract ERC165 is Initializable, IERC165 {\n bytes4 private constant _INTERFACE_ID_ERC165 = 0x01ffc9a7;\n /**\n * 0x01ffc9a7 ===\n * bytes4(keccak256('supportsInterface(bytes4)'))\n */\n\n /**\n * @dev a mapping of interface id to whether or not it's supported\n */\n mapping(bytes4 => bool) private _supportedInterfaces;\n\n /**\n * @dev A contract implementing SupportsInterfaceWithLookup\n * implement ERC165 itself\n */\n function initializeERC165() public initializer {\n _registerInterface(_INTERFACE_ID_ERC165);\n }\n\n /**\n * @dev implement supportsInterface(bytes4) using a lookup table\n */\n function supportsInterface(bytes4 interfaceId) public view override returns (bool) {\n return _supportedInterfaces[interfaceId];\n }\n\n /**\n * @dev internal method for registering an interface\n */\n function _registerInterface(bytes4 interfaceId) internal {\n require(interfaceId != 0xffffffff);\n _supportedInterfaces[interfaceId] = true;\n }\n\n uint256[50] private ______gap;\n}\n\n// File: contracts/token/MockERC721/MockERC721.sol\n\n/**\n * @title MockERC721 Non-Fungible Token Standard basic implementation\n * @dev see https://github.com/ethereum/EIPs/blob/master/EIPS/eip-721.md\n */\ncontract MockERC721 is Initializable, ERC165, IMockERC721 {\n using SafeMath for uint256;\n using Address for address;\n\n // Equals to `bytes4(keccak256(\"onMockERC721Received(address,address,uint256,bytes)\"))`\n // which can be also obtained as `IMockERC721Receiver(0).onMockERC721Received.selector`\n bytes4 private constant _MockERC721_RECEIVED = 0x150b7a02;\n\n // Mapping from token ID to owner\n mapping (uint256 => address) private _tokenOwner;\n\n // Mapping from token ID to approved address\n mapping (uint256 => address) private _tokenApprovals;\n\n // Mapping from owner to number of owned token\n mapping (address => uint256) private _ownedTokensCount;\n\n // Mapping from owner to operator approvals\n mapping (address => mapping (address => bool)) private _operatorApprovals;\n\n bytes4 private constant _INTERFACE_ID_MockERC721 = 0x80ac58cd;\n /*\n * 0x80ac58cd ===\n * bytes4(keccak256('balanceOf(address)')) ^\n * bytes4(keccak256('ownerOf(uint256)')) ^\n * bytes4(keccak256('approve(address,uint256)')) ^\n * bytes4(keccak256('getApproved(uint256)')) ^\n * bytes4(keccak256('setApprovalForAll(address,bool)')) ^\n * bytes4(keccak256('isApprovedForAll(address,address)')) ^\n * bytes4(keccak256('transferFrom(address,address,uint256)')) ^\n * bytes4(keccak256('safeTransferFrom(address,address,uint256)')) ^\n * bytes4(keccak256('safeTransferFrom(address,address,uint256,bytes)'))\n */\n\n function initialize() public initializer virtual {\n ERC165.initializeERC165();\n\n // register the supported interfaces to conform to MockERC721 via ERC165\n _registerInterface(_INTERFACE_ID_MockERC721);\n }\n\n function _hasBeenInitializedMockERC721() internal view virtual returns (bool) {\n return supportsInterface(_INTERFACE_ID_MockERC721);\n }\n\n /**\n * @dev Gets the balance of the specified address\n * @param owner address to query the balance of\n * @return uint256 representing the amount owned by the passed address\n */\n function balanceOf(address owner) public view returns (uint256) {\n require(owner != address(0));\n return _ownedTokensCount[owner];\n }\n\n /**\n * @dev Gets the owner of the specified token ID\n * @param tokenId uint256 ID of the token to query the owner of\n * @return owner address currently marked as the owner of the given token ID\n */\n function ownerOf(uint256 tokenId) public view returns (address) {\n address owner = _tokenOwner[tokenId];\n require(owner != address(0));\n return owner;\n }\n\n /**\n * @dev Approves another address to transfer the given token ID\n * The zero address indicates there is no approved address.\n * There can only be one approved address per token at a given time.\n * Can only be called by the token owner or an approved operator.\n * @param to address to be approved for the given token ID\n * @param tokenId uint256 ID of the token to be approved\n */\n function approveMockERC721(address to, uint256 tokenId) public {\n address owner = ownerOf(tokenId);\n require(to != owner);\n require(msg.sender == owner || isApprovedForAll(owner, msg.sender));\n\n _tokenApprovals[tokenId] = to;\n emit Approval(owner, to, tokenId);\n }\n\n /**\n * @dev Gets the approved address for a token ID, or zero if no address set\n * Reverts if the token ID does not exist.\n * @param tokenId uint256 ID of the token to query the approval of\n * @return address currently approved for the given token ID\n */\n function getApproved(uint256 tokenId) public view returns (address) {\n require(_exists(tokenId));\n return _tokenApprovals[tokenId];\n }\n\n /**\n * @dev Sets or unsets the approval of a given operator\n * An operator is allowed to transfer all tokens of the sender on their behalf\n * @param to operator address to set the approval\n * @param approved representing the status of the approval to be set\n */\n function setApprovalForAllMockERC721(address to, bool approved) public {\n require(to != msg.sender);\n _operatorApprovals[msg.sender][to] = approved;\n emit ApprovalForAll(msg.sender, to, approved);\n }\n\n /**\n * @dev Tells whether an operator is approved by a given owner\n * @param owner owner address which you want to query the approval of\n * @param operator operator address which you want to query the approval of\n * @return bool whether the given operator is approved by the given owner\n */\n function isApprovedForAll(address owner, address operator) public view returns (bool) {\n return _operatorApprovals[owner][operator];\n }\n\n /**\n * @dev Transfers the ownership of a given token ID to another address\n * Usage of this method is discouraged, use `safeTransferFrom` whenever possible\n * Requires the msg sender to be the owner, approved, or operator\n * @param from current owner of the token\n * @param to address to receive the ownership of the given token ID\n * @param tokenId uint256 ID of the token to be transferred\n */\n function transferFromMockERC721(address from, address to, uint256 tokenId) public virtual {\n require(_isApprovedOrOwner(msg.sender, tokenId));\n\n _transferFromMockERC721(from, to, tokenId);\n }\n\n /**\n * @dev Safely transfers the ownership of a given token ID to another address\n * If the target address is a contract, it must implement `onMockERC721Received`,\n * which is called upon a safe transfer, and return the magic value\n * `bytes4(keccak256(\"onMockERC721Received(address,address,uint256,bytes)\"))`; otherwise,\n * the transfer is reverted.\n *\n * Requires the msg sender to be the owner, approved, or operator\n * @param from current owner of the token\n * @param to address to receive the ownership of the given token ID\n * @param tokenId uint256 ID of the token to be transferred\n */\n function safeTransferFrom(address from, address to, uint256 tokenId) public {\n safeTransferFrom(from, to, tokenId, \"\");\n }\n\n /**\n * @dev Safely transfers the ownership of a given token ID to another address\n * If the target address is a contract, it must implement `onMockERC721Received`,\n * which is called upon a safe transfer, and return the magic value\n * `bytes4(keccak256(\"onMockERC721Received(address,address,uint256,bytes)\"))`; otherwise,\n * the transfer is reverted.\n * Requires the msg sender to be the owner, approved, or operator\n * @param from current owner of the token\n * @param to address to receive the ownership of the given token ID\n * @param tokenId uint256 ID of the token to be transferred\n * @param _data bytes data to send along with a safe transfer check\n */\n function safeTransferFrom(address from, address to, uint256 tokenId, bytes memory _data) public {\n transferFromMockERC721(from, to, tokenId);\n require(_checkOnMockERC721Received(from, to, tokenId, _data));\n }\n\n /**\n * @dev Returns whether the specified token exists\n * @param tokenId uint256 ID of the token to query the existence of\n * @return whether the token exists\n */\n function _exists(uint256 tokenId) internal view returns (bool) {\n address owner = _tokenOwner[tokenId];\n return owner != address(0);\n }\n\n /**\n * @dev Returns whether the given spender can transfer a given token ID\n * @param spender address of the spender to query\n * @param tokenId uint256 ID of the token to be transferred\n * @return bool whether the msg.sender is approved for the given token ID,\n * is an operator of the owner, or is the owner of the token\n */\n function _isApprovedOrOwner(address spender, uint256 tokenId) internal view returns (bool) {\n address owner = ownerOf(tokenId);\n return (spender == owner || getApproved(tokenId) == spender || isApprovedForAll(owner, spender));\n }\n\n /**\n * @dev Internal function to mint a new token\n * Reverts if the given token ID already exists\n * @param to The address that will own the minted token\n * @param tokenId uint256 ID of the token to be minted\n */\n function _mintMockERC721(address to, uint256 tokenId) internal {\n require(to != address(0));\n require(!_exists(tokenId));\n\n _tokenOwner[tokenId] = to;\n _ownedTokensCount[to] = _ownedTokensCount[to].add(1);\n\n emit Transfer(address(0), to, tokenId);\n }\n\n /**\n * @dev Internal function to burn a specific token\n * Reverts if the token does not exist\n * Deprecated, use _burn(uint256) instead.\n * @param owner owner of the token to burn\n * @param tokenId uint256 ID of the token being burned\n */\n function _burnMockERC721(address owner, uint256 tokenId) internal {\n require(ownerOf(tokenId) == owner);\n\n _clearApproval(tokenId);\n\n _ownedTokensCount[owner] = _ownedTokensCount[owner].sub(1);\n _tokenOwner[tokenId] = address(0);\n\n emit Transfer(owner, address(0), tokenId);\n }\n\n /**\n * @dev Internal function to burn a specific token\n * Reverts if the token does not exist\n * @param tokenId uint256 ID of the token being burned\n */\n function _burn(uint256 tokenId) internal {\n _burnMockERC721(ownerOf(tokenId), tokenId);\n }\n\n /**\n * @dev Internal function to transfer ownership of a given token ID to another address.\n * As opposed to transferFrom, this imposes no restrictions on msg.sender.\n * @param from current owner of the token\n * @param to address to receive the ownership of the given token ID\n * @param tokenId uint256 ID of the token to be transferred\n */\n function _transferFromMockERC721(address from, address to, uint256 tokenId) internal {\n require(ownerOf(tokenId) == from);\n require(to != address(0));\n\n _clearApproval(tokenId);\n\n _ownedTokensCount[from] = _ownedTokensCount[from].sub(1);\n _ownedTokensCount[to] = _ownedTokensCount[to].add(1);\n\n _tokenOwner[tokenId] = to;\n\n emit Transfer(from, to, tokenId);\n }\n\n /**\n * @dev Internal function to invoke `onMockERC721Received` on a target address\n * The call is not executed if the target address is not a contract\n * @param from address representing the previous owner of the given token ID\n * @param to target address that will receive the tokens\n * @param tokenId uint256 ID of the token to be transferred\n * @param _data bytes optional data to send along with the call\n * @return whether the call correctly returned the expected magic value\n */\n function _checkOnMockERC721Received(address from, address to, uint256 tokenId, bytes memory _data)\n internal returns (bool)\n {\n if (!to.isContract()) {\n return true;\n }\n\n bytes4 retval = IMockERC721Receiver(to).onMockERC721Received(msg.sender, from, tokenId, _data);\n return (retval == _MockERC721_RECEIVED);\n }\n\n /**\n * @dev Private function to clear current approval of a given token ID\n * @param tokenId uint256 ID of the token to be transferred\n */\n function _clearApproval(uint256 tokenId) private {\n if (_tokenApprovals[tokenId] != address(0)) {\n _tokenApprovals[tokenId] = address(0);\n }\n }\n\n uint256[50] private ______gap;\n}\n\n// File: contracts/token/MockERC721/IMockERC721Enumerable.sol\n\n\n\n/**\n * @title ERC-721 Non-Fungible Token Standard, optional enumeration extension\n * @dev See https://github.com/ethereum/EIPs/blob/master/EIPS/eip-721.md\n */\nabstract contract IMockERC721Enumerable is Initializable, IMockERC721 {\n function totalSupply() public view virtual returns (uint256);\n function tokenOfOwnerByIndex(address owner, uint256 index) public view virtual returns (uint256 tokenId);\n\n function tokenByIndex(uint256 index) public view virtual returns (uint256);\n}\n\n// File: contracts/token/MockERC721/MockERC721Enumerable.sol\n\n\n\n\n\n/**\n * @title ERC-721 Non-Fungible Token with optional enumeration extension logic\n * @dev See https://github.com/ethereum/EIPs/blob/master/EIPS/eip-721.md\n */\ncontract MockERC721Enumerable is Initializable, ERC165, MockERC721, IMockERC721Enumerable {\n // Mapping from owner to list of owned token IDs\n mapping(address => uint256[]) private _ownedTokens;\n\n // Mapping from token ID to index of the owner tokens list\n mapping(uint256 => uint256) private _ownedTokensIndex;\n\n // Array with all token ids, used for enumeration\n uint256[] private _allTokens;\n\n // Mapping from token id to position in the allTokens array\n mapping(uint256 => uint256) private _allTokensIndex;\n\n bytes4 private constant _INTERFACE_ID_MockERC721_ENUMERABLE = 0x780e9d63;\n /**\n * 0x780e9d63 ===\n * bytes4(keccak256('totalSupply()')) ^\n * bytes4(keccak256('tokenOfOwnerByIndex(address,uint256)')) ^\n * bytes4(keccak256('tokenByIndex(uint256)'))\n */\n\n /**\n * @dev Constructor function\n */\n function initializeMockERC721Enumerable() public initializer {\n require(MockERC721._hasBeenInitializedMockERC721());\n\n // register the supported interface to conform to MockERC721 via ERC165\n _registerInterface(_INTERFACE_ID_MockERC721_ENUMERABLE);\n }\n\n function _hasBeenInitialized() internal view virtual returns (bool) {\n return supportsInterface(_INTERFACE_ID_MockERC721_ENUMERABLE);\n }\n\n /**\n * @dev Gets the token ID at a given index of the tokens list of the requested owner\n * @param owner address owning the tokens list to be accessed\n * @param index uint256 representing the index to be accessed of the requested tokens list\n * @return uint256 token ID at the given index of the tokens list owned by the requested address\n */\n function tokenOfOwnerByIndex(address owner, uint256 index) public view override returns (uint256) {\n require(index < balanceOf(owner));\n return _ownedTokens[owner][index];\n }\n\n /**\n * @dev Gets the total amount of tokens stored by the contract\n * @return uint256 representing the total amount of tokens\n */\n function totalSupply() public view override returns (uint256) {\n return _allTokens.length;\n }\n\n /**\n * @dev Gets the token ID at a given index of all the tokens in this contract\n * Reverts if the index is greater or equal to the total number of tokens\n * @param index uint256 representing the index to be accessed of the tokens list\n * @return uint256 token ID at the given index of the tokens list\n */\n function tokenByIndex(uint256 index) public view override returns (uint256) {\n require(index < totalSupply());\n return _allTokens[index];\n }\n\n /**\n * @dev Internal function to transfer ownership of a given token ID to another address.\n * As opposed to transferFrom, this imposes no restrictions on msg.sender.\n * @param from current owner of the token\n * @param to address to receive the ownership of the given token ID\n * @param tokenId uint256 ID of the token to be transferred\n */\n function _transferFrom(address from, address to, uint256 tokenId) internal {\n super._transferFromMockERC721(from, to, tokenId);\n\n _removeTokenFromOwnerEnumeration(from, tokenId);\n\n _addTokenToOwnerEnumeration(to, tokenId);\n }\n\n /**\n * @dev Internal function to mint a new token\n * Reverts if the given token ID already exists\n * @param to address the beneficiary that will own the minted token\n * @param tokenId uint256 ID of the token to be minted\n */\n function _mint(address to, uint256 tokenId) internal virtual {\n super._mintMockERC721(to, tokenId);\n\n _addTokenToOwnerEnumeration(to, tokenId);\n\n _addTokenToAllTokensEnumeration(tokenId);\n }\n\n /**\n * @dev Internal function to burn a specific token\n * Reverts if the token does not exist\n * Deprecated, use _burn(uint256) instead\n * @param owner owner of the token to burn\n * @param tokenId uint256 ID of the token being burned\n */\n function _burn(address owner, uint256 tokenId) internal virtual {\n super._burnMockERC721(owner, tokenId);\n\n _removeTokenFromOwnerEnumeration(owner, tokenId);\n // Since tokenId will be deleted, we can clear its slot in _ownedTokensIndex to trigger a gas refund\n _ownedTokensIndex[tokenId] = 0;\n\n _removeTokenFromAllTokensEnumeration(tokenId);\n }\n\n /**\n * @dev Gets the list of token IDs of the requested owner\n * @param owner address owning the tokens\n * @return uint256[] List of token IDs owned by the requested address\n */\n function _tokensOfOwner(address owner) internal view returns (uint256[] storage) {\n return _ownedTokens[owner];\n }\n\n /**\n * @dev Private function to add a token to this extension's ownership-tracking data structures.\n * @param to address representing the new owner of the given token ID\n * @param tokenId uint256 ID of the token to be added to the tokens list of the given address\n */\n function _addTokenToOwnerEnumeration(address to, uint256 tokenId) private {\n _ownedTokensIndex[tokenId] = _ownedTokens[to].length;\n _ownedTokens[to].push(tokenId);\n }\n\n /**\n * @dev Private function to add a token to this extension's token tracking data structures.\n * @param tokenId uint256 ID of the token to be added to the tokens list\n */\n function _addTokenToAllTokensEnumeration(uint256 tokenId) private {\n _allTokensIndex[tokenId] = _allTokens.length;\n _allTokens.push(tokenId);\n }\n\n /**\n * @dev Private function to remove a token from this extension's ownership-tracking data structures. Note that\n * while the token is not assigned a new owner, the _ownedTokensIndex mapping is _not_ updated: this allows for\n * gas optimizations e.g. when performing a transfer operation (avoiding double writes).\n * This has O(1) time complexity, but alters the order of the _ownedTokens array.\n * @param from address representing the previous owner of the given token ID\n * @param tokenId uint256 ID of the token to be removed from the tokens list of the given address\n */\n function _removeTokenFromOwnerEnumeration(address from, uint256 tokenId) private {\n // To prevent a gap in from's tokens array, we store the last token in the index of the token to delete, and\n // then delete the last slot (swap and pop).\n\n uint256 lastTokenIndex = _ownedTokens[from].length.sub(1);\n uint256 tokenIndex = _ownedTokensIndex[tokenId];\n\n // When the token to delete is the last token, the swap operation is unnecessary\n if (tokenIndex != lastTokenIndex) {\n uint256 lastTokenId = _ownedTokens[from][lastTokenIndex];\n\n _ownedTokens[from][tokenIndex] = lastTokenId; // Move the last token to the slot of the to-delete token\n _ownedTokensIndex[lastTokenId] = tokenIndex; // Update the moved token's index\n }\n\n // This also deletes the contents at the last position of the array\n //_ownedTokens[from].length--;\n _ownedTokens[from].pop();\n // Note that _ownedTokensIndex[tokenId] hasn't been cleared: it still points to the old slot (now occcupied by\n // lasTokenId, or just over the end of the array if the token was the last one).\n }\n\n /**\n * @dev Private function to remove a token from this extension's token tracking data structures.\n * This has O(1) time complexity, but alters the order of the _allTokens array.\n * @param tokenId uint256 ID of the token to be removed from the tokens list\n */\n function _removeTokenFromAllTokensEnumeration(uint256 tokenId) private {\n // To prevent a gap in the tokens array, we store the last token in the index of the token to delete, and\n // then delete the last slot (swap and pop).\n\n uint256 lastTokenIndex = _allTokens.length.sub(1);\n uint256 tokenIndex = _allTokensIndex[tokenId];\n\n // When the token to delete is the last token, the swap operation is unnecessary. However, since this occurs so\n // rarely (when the last minted token is burnt) that we still do the swap here to avoid the gas cost of adding\n // an 'if' statement (like in _removeTokenFromOwnerEnumeration)\n uint256 lastTokenId = _allTokens[lastTokenIndex];\n\n _allTokens[tokenIndex] = lastTokenId; // Move the last token to the slot of the to-delete token\n _allTokensIndex[lastTokenId] = tokenIndex; // Update the moved token's index\n\n // This also deletes the contents at the last position of the array\n _allTokens.pop();\n //_allTokensIndex[tokenId] = 0;\n }\n\n uint256[50] private ______gap;\n}\n\n// File: contracts/token/MockERC721/IMockERC721Metadata.sol\n\n\n\n/**\n * @title ERC-721 Non-Fungible Token Standard, optional metadata extension\n * @dev See https://github.com/ethereum/EIPs/blob/master/EIPS/eip-721.md\n */\nabstract contract IMockERC721Metadata is Initializable, IMockERC721 {\n function name() external view virtual returns (string memory);\n function symbol() external view virtual returns (string memory);\n function tokenURI(uint256 tokenId) external view virtual returns (string memory);\n}\n\n// File: contracts/token/MockERC721/MockERC721Metadata.sol\n\n\n\n\n\ncontract MockERC721Metadata is Initializable, ERC165, MockERC721, IMockERC721Metadata {\n // Token name\n string private _name;\n\n // Token symbol\n string private _symbol;\n\n // Optional mapping for token URIs\n mapping(uint256 => string) private _tokenURIs;\n\n bytes4 private constant _INTERFACE_ID_MockERC721_METADATA = 0x5b5e139f;\n /**\n * 0x5b5e139f ===\n * bytes4(keccak256('name()')) ^\n * bytes4(keccak256('symbol()')) ^\n * bytes4(keccak256('tokenURI(uint256)'))\n */\n\n /**\n * @dev Constructor function\n */\n function initialize(string memory name, string memory symbol) public initializer {\n require(MockERC721._hasBeenInitializedMockERC721());\n\n _name = name;\n _symbol = symbol;\n\n // register the supported interfaces to conform to MockERC721 via ERC165\n _registerInterface(_INTERFACE_ID_MockERC721_METADATA);\n }\n\n function _hasBeenInitialized() internal view virtual returns (bool) {\n return supportsInterface(_INTERFACE_ID_MockERC721_METADATA);\n }\n\n /**\n * @dev Gets the token name\n * @return string representing the token name\n */\n function name() external view override returns (string memory) {\n return _name;\n }\n\n /**\n * @dev Gets the token symbol\n * @return string representing the token symbol\n */\n function symbol() external view override returns (string memory) {\n return _symbol;\n }\n\n /**\n * @dev Returns an URI for a given token ID\n * Throws if the token ID does not exist. May return an empty string.\n * @param tokenId uint256 ID of the token to query\n */\n function tokenURI(uint256 tokenId) external view override returns (string memory) {\n require(_exists(tokenId));\n return _tokenURIs[tokenId];\n }\n\n /**\n * @dev Internal function to set the token URI for a given token\n * Reverts if the token ID does not exist\n * @param tokenId uint256 ID of the token to set its URI\n * @param uri string URI to assign\n */\n function _setTokenURI(uint256 tokenId, string memory uri) internal {\n require(_exists(tokenId));\n _tokenURIs[tokenId] = uri;\n }\n\n /**\n * @dev Internal function to burn a specific token\n * Reverts if the token does not exist\n * Deprecated, use _burn(uint256) instead\n * @param owner owner of the token to burn\n * @param tokenId uint256 ID of the token being burned by the msg.sender\n */\n function _burn(address owner, uint256 tokenId) internal virtual {\n super._burnMockERC721(owner, tokenId);\n\n // Clear metadata (if any)\n if (bytes(_tokenURIs[tokenId]).length != 0) {\n delete _tokenURIs[tokenId];\n }\n }\n\n uint256[50] private ______gap;\n}\n\n// File: contracts/access/Roles.sol\n\n/**\n * @title Roles\n * @dev Library for managing addresses assigned to a Role.\n */\nlibrary Roles {\n struct Role {\n mapping (address => bool) bearer;\n }\n\n /**\n * @dev give an account access to this role\n */\n function add(Role storage role, address account) internal {\n require(account != address(0));\n require(!has(role, account));\n\n role.bearer[account] = true;\n }\n\n /**\n * @dev remove an account's access to this role\n */\n function remove(Role storage role, address account) internal {\n require(account != address(0));\n require(has(role, account));\n\n role.bearer[account] = false;\n }\n\n /**\n * @dev check if an account has this role\n * @return bool\n */\n function has(Role storage role, address account) internal view returns (bool) {\n require(account != address(0));\n return role.bearer[account];\n }\n}\n\n// File: contracts/access/roles/MinterRole.sol\n\n\n\n\ncontract MinterRole is Initializable {\n using Roles for Roles.Role;\n\n event MinterAdded(address indexed account);\n event MinterRemoved(address indexed account);\n\n Roles.Role private _minters;\n\n function initializeMinterRole(address sender) public initializer {\n if (!isMinter(sender)) {\n _addMinter(sender);\n }\n }\n\n modifier onlyMinter() {\n require(isMinter(msg.sender));\n _;\n }\n\n function isMinter(address account) public view returns (bool) {\n return _minters.has(account);\n }\n\n function addMinter(address account) public onlyMinter {\n _addMinter(account);\n }\n\n function renounceMinter() public {\n _removeMinter(msg.sender);\n }\n\n function _addMinter(address account) internal {\n _minters.add(account);\n emit MinterAdded(account);\n }\n\n function _removeMinter(address account) internal {\n _minters.remove(account);\n emit MinterRemoved(account);\n }\n\n uint256[50] private ______gap;\n}\n\n// File: contracts/token/MockERC721/MockERC721MetadataMintable.sol\n\n\n\n\n\n/**\n * @title MockERC721MetadataMintable\n * @dev MockERC721 minting logic with metadata\n */\ncontract MockERC721MetadataMintable is Initializable, MockERC721, MockERC721Metadata, MinterRole {\n function initializeMockERC721MetadataMintable(address sender) public initializer {\n require(MockERC721._hasBeenInitializedMockERC721());\n require(MockERC721Metadata._hasBeenInitialized());\n MinterRole.initializeMinterRole(sender);\n }\n\n // function _burn(address owner, uint256 tokenId) internal override(MockERC721Metadata) {\n // MockERC721Metadata._burn(owner, tokenId);\n // }\n\n /**\n * @dev Function to mint tokens\n * @param to The address that will receive the minted tokens.\n * @param tokenId The token id to mint.\n * @param tokenURI The token URI of the minted token.\n * @return A boolean that indicates if the operation was successful.\n */\n function mintWithTokenURI(address to, uint256 tokenId, string memory tokenURI) public onlyMinter returns (bool) {\n _mintMockERC721(to, tokenId);\n _setTokenURI(tokenId, tokenURI);\n return true;\n }\n\n uint256[50] private ______gap;\n}\n\n// File: contracts/access/roles/PauserRole.sol\n\n\n\n\ncontract PauserRole is Initializable {\n using Roles for Roles.Role;\n\n event PauserAdded(address indexed account);\n event PauserRemoved(address indexed account);\n\n Roles.Role private _pausers;\n\n function initializePauserRole(address sender) public initializer {\n if (!isPauser(sender)) {\n _addPauser(sender);\n }\n }\n\n modifier onlyPauser() {\n require(isPauser(msg.sender));\n _;\n }\n\n function isPauser(address account) public view returns (bool) {\n return _pausers.has(account);\n }\n\n function addPauser(address account) public onlyPauser {\n _addPauser(account);\n }\n\n function renouncePauser() public {\n _removePauser(msg.sender);\n }\n\n function _addPauser(address account) internal {\n _pausers.add(account);\n emit PauserAdded(account);\n }\n\n function _removePauser(address account) internal {\n _pausers.remove(account);\n emit PauserRemoved(account);\n }\n\n uint256[50] private ______gap;\n}\n\n// File: contracts/lifecycle/Pausable.sol\n\n\n\n/**\n * @title Pausable\n * @dev Base contract which allows children to implement an emergency stop mechanism.\n */\ncontract Pausable is Initializable, PauserRole {\n event Paused(address account);\n event Unpaused(address account);\n\n bool private _paused;\n\n function initializePausable(address sender) public initializer {\n PauserRole.initializePauserRole(sender);\n\n _paused = false;\n }\n\n /**\n * @return true if the contract is paused, false otherwise.\n */\n function paused() public view returns (bool) {\n return _paused;\n }\n\n /**\n * @dev Modifier to make a function callable only when the contract is not paused.\n */\n modifier whenNotPaused() {\n require(!_paused);\n _;\n }\n\n /**\n * @dev Modifier to make a function callable only when the contract is paused.\n */\n modifier whenPaused() {\n require(_paused);\n _;\n }\n\n /**\n * @dev called by the owner to pause, triggers stopped state\n */\n function pause() public onlyPauser whenNotPaused {\n _paused = true;\n emit Paused(msg.sender);\n }\n\n /**\n * @dev called by the owner to unpause, returns to normal state\n */\n function unpause() public onlyPauser whenPaused {\n _paused = false;\n emit Unpaused(msg.sender);\n }\n\n uint256[50] private ______gap;\n}\n\n// File: contracts/token/MockERC721/MockERC721Pausable.sol\n\n\n\n\n/**\n * @title MockERC721 Non-Fungible Pausable token\n * @dev MockERC721 modified with pausable transfers.\n **/\ncontract MockERC721Pausable is Initializable, MockERC721, Pausable {\n function initialize(address sender) public initializer {\n require(MockERC721._hasBeenInitializedMockERC721());\n Pausable.initializePausable(sender);\n }\n\n function approve(address to, uint256 tokenId) public whenNotPaused {\n super.approveMockERC721(to, tokenId);\n }\n\n function setApprovalForAll(address to, bool approved) public whenNotPaused {\n super.setApprovalForAllMockERC721(to, approved);\n }\n\n function transferFrom(address from, address to, uint256 tokenId) public whenNotPaused {\n super.transferFromMockERC721(from, to, tokenId);\n }\n\n uint256[50] private ______gap;\n}\n\n// File: contracts/token/MockERC721/StandaloneMockERC721.sol\n\n\n\n\n\n\n\n\n/**\n * @title Standard MockERC721 token, with minting and pause functionality.\n *\n */\ncontract MockStandaloneERC721\n is Initializable, MockERC721, MockERC721Enumerable, MockERC721Metadata, MockERC721MetadataMintable, MockERC721Pausable\n{\n function initialize(string memory name, string memory symbol, address[] memory minters, address[] memory pausers) public initializer {\n MockERC721.initialize();\n MockERC721Enumerable.initializeMockERC721Enumerable();\n MockERC721Metadata.initialize(name, symbol);\n\n // Initialize the minter and pauser roles, and renounce them\n MockERC721MetadataMintable.initializeMockERC721MetadataMintable(address(this));\n _removeMinter(address(this));\n\n MockERC721Pausable.initialize(address(this));\n _removePauser(address(this));\n\n // Add the requested minters and pausers (this can be done after renouncing since\n // these are the internal calls)\n for (uint256 i = 0; i < minters.length; ++i) {\n _addMinter(minters[i]);\n }\n\n for (uint256 i = 0; i < pausers.length; ++i) {\n _addPauser(pausers[i]);\n }\n }\n\n // function transferFrom(address from, address to, uint256 tokenId) public override {\n // require(_isApprovedOrOwner(msg.sender, tokenId));\n //\n // _transferFrom(from, to, tokenId);\n // }\n\n // function setApprovalForAll(address to, bool approved) public override {\n // MockERC721.setApprovalForAll(to, approved);\n // }\n\n // function initialize(address sender) public initializer override {\n // require(MockERC721._hasBeenInitializedMockERC721());\n // require(MockERC721Metadata._hasBeenInitialized());\n // MinterRole.initialize(sender);\n // }\n\n // function initialize() public initializer override(ERC165) {\n // ERC165.initializeERC165();\n // }\n function _burn(address owner, uint256 tokenId) internal override(MockERC721Enumerable,MockERC721Metadata) {\n MockERC721Enumerable._burn(owner, tokenId);\n MockERC721Metadata._burn(owner, tokenId);\n\n }\n function _hasBeenInitialized() internal view override(MockERC721Enumerable, MockERC721Metadata) returns (bool) {\n MockERC721Enumerable._hasBeenInitialized();\n MockERC721Metadata._hasBeenInitialized();\n\n }\n\n function _mint(address to, uint256 tokenId) internal override(MockERC721Enumerable) {\n MockERC721Enumerable._mint(to,tokenId);\n }\n}\n",
"sourcePath": "contracts/mocks/MockStandaloneERC721.sol",
"sourceMap": "",
"deployedSourceMap": "",
"abi": [
{
"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": "from",
"type": "address"
},
{
"indexed": true,
"internalType": "address",
"name": "to",
"type": "address"
},
{
"indexed": true,
"internalType": "uint256",
"name": "tokenId",
"type": "uint256"
}
],
"name": "Transfer",
"type": "event"
},
{
"inputs": [
{
"internalType": "bytes4",
"name": "interfaceId",
"type": "bytes4"
}
],
"name": "supportsInterface",
"outputs": [
{
"internalType": "bool",
"name": "",
"type": "bool"
}
],
"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": "tokenId",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "totalSupply",
"outputs": [
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
}
],
"ast": {
"absolutePath": "contracts/mocks/MockStandaloneERC721.sol",
"exportedSymbols": {
"Address": [
2173
],
"ERC165": [
2235
],
"IERC165": [
1976
],
"IMockERC721": [
2006
],
"IMockERC721Enumerable": [
2865
],
"IMockERC721Metadata": [
3252
],
"IMockERC721Receiver": [
2022
],
"MinterRole": [
3622
],
"MockERC721": [
2838
],
"MockERC721Enumerable": [
3229
],
"MockERC721Metadata": [
3408
],
"MockERC721MetadataMintable": [
3689
],
"MockERC721Pausable": [
3992
],
"MockStandaloneERC721": [
4170
],
"Pausable": [
3906
],
"PauserRole": [
3804
],
"Roles": [
3507
],
"SafeMath": [
2154
]
},
"id": 4171,
"license": "MIT",
"nodeType": "SourceUnit",
"nodes": [
{
"id": 1965,
"literals": [
"solidity",
"^",
"0.6",
".0"
],
"nodeType": "PragmaDirective",
"src": "0:23:13"
},
{
"absolutePath": "contracts/Initializable.sol",
"file": "../Initializable.sol",
"id": 1966,
"nodeType": "ImportDirective",
"scope": 4171,
"sourceUnit": 75,
"src": "57:30:13",
"symbolAliases": [],
"unitAlias": ""
},
{
"abstract": false,
"baseContracts": [],
"contractDependencies": [],
"contractKind": "interface",
"documentation": {
"id": 1967,
"nodeType": "StructuredDocumentation",
"src": "135:94:13",
"text": " @title IERC165\n @dev https://github.com/ethereum/EIPs/blob/master/EIPS/eip-165.md"
},
"fullyImplemented": false,
"id": 1976,
"linearizedBaseContracts": [
1976
],
"name": "IERC165",
"nodeType": "ContractDefinition",
"nodes": [
{
"body": null,
"documentation": {
"id": 1968,
"nodeType": "StructuredDocumentation",
"src": "254:256:13",
"text": " @notice Query if a contract implements an interface\n @param interfaceId The interface identifier, as specified in ERC-165\n @dev Interface identification is specified in ERC-165. This function\n uses less than 30,000 gas."
},
"functionSelector": "01ffc9a7",
"id": 1975,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "supportsInterface",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 1971,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 1970,
"mutability": "mutable",
"name": "interfaceId",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1975,
"src": "542:18:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
},
"typeName": {
"id": 1969,
"name": "bytes4",
"nodeType": "ElementaryTypeName",
"src": "542:6:13",
"typeDescriptions": {
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "541:20:13"
},
"returnParameters": {
"id": 1974,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 1973,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1975,
"src": "585:4:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 1972,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "585:4:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "584:6:13"
},
"scope": 1976,
"src": "515:76:13",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
}
],
"scope": 4171,
"src": "230:363:13"
},
{
"abstract": true,
"baseContracts": [
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 1978,
"name": "Initializable",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 74,
"src": "829:13:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_Initializable_$74",
"typeString": "contract Initializable"
}
},
"id": 1979,
"nodeType": "InheritanceSpecifier",
"src": "829:13:13"
},
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 1980,
"name": "IERC165",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 1976,
"src": "844:7:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IERC165_$1976",
"typeString": "contract IERC165"
}
},
"id": 1981,
"nodeType": "InheritanceSpecifier",
"src": "844:7:13"
}
],
"contractDependencies": [
74,
1976
],
"contractKind": "contract",
"documentation": {
"id": 1977,
"nodeType": "StructuredDocumentation",
"src": "650:145:13",
"text": " @title MockERC721 Non-Fungible Token Standard basic interface\n @dev see https://github.com/ethereum/EIPs/blob/master/EIPS/eip-721.md"
},
"fullyImplemented": false,
"id": 2006,
"linearizedBaseContracts": [
2006,
1976,
74
],
"name": "IMockERC721",
"nodeType": "ContractDefinition",
"nodes": [
{
"anonymous": false,
"documentation": null,
"id": 1989,
"name": "Transfer",
"nodeType": "EventDefinition",
"parameters": {
"id": 1988,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 1983,
"indexed": true,
"mutability": "mutable",
"name": "from",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1989,
"src": "873:20:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 1982,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "873:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 1985,
"indexed": true,
"mutability": "mutable",
"name": "to",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1989,
"src": "895:18:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 1984,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "895:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 1987,
"indexed": true,
"mutability": "mutable",
"name": "tokenId",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1989,
"src": "915:23:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 1986,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "915:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "872:67:13"
},
"src": "858:82:13"
},
{
"anonymous": false,
"documentation": null,
"id": 1997,
"name": "Approval",
"nodeType": "EventDefinition",
"parameters": {
"id": 1996,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 1991,
"indexed": true,
"mutability": "mutable",
"name": "owner",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1997,
"src": "960:21:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 1990,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "960:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 1993,
"indexed": true,
"mutability": "mutable",
"name": "approved",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1997,
"src": "983:24:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 1992,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "983:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 1995,
"indexed": true,
"mutability": "mutable",
"name": "tokenId",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1997,
"src": "1009:23:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 1994,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "1009:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "959:74:13"
},
"src": "945:89:13"
},
{
"anonymous": false,
"documentation": null,
"id": 2005,
"name": "ApprovalForAll",
"nodeType": "EventDefinition",
"parameters": {
"id": 2004,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 1999,
"indexed": true,
"mutability": "mutable",
"name": "owner",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2005,
"src": "1060:21:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 1998,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "1060:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 2001,
"indexed": true,
"mutability": "mutable",
"name": "operator",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2005,
"src": "1083:24:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 2000,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "1083:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 2003,
"indexed": false,
"mutability": "mutable",
"name": "approved",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2005,
"src": "1109:13:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 2002,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "1109:4:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "1059:64:13"
},
"src": "1039:85:13"
}
],
"scope": 4171,
"src": "796:1173:13"
},
{
"abstract": true,
"baseContracts": [],
"contractDependencies": [],
"contractKind": "contract",
"documentation": {
"id": 2007,
"nodeType": "StructuredDocumentation",
"src": "2032:160:13",
"text": " @title MockERC721 token receiver interface\n @dev Interface for any contract that wants to support safeTransfers\n from MockERC721 asset contracts."
},
"fullyImplemented": false,
"id": 2022,
"linearizedBaseContracts": [
2022
],
"name": "IMockERC721Receiver",
"nodeType": "ContractDefinition",
"nodes": [
{
"body": null,
"documentation": {
"id": 2008,
"nodeType": "StructuredDocumentation",
"src": "2237:862:13",
"text": " @notice Handle the receipt of an NFT\n @dev The MockERC721 smart contract calls this function on the recipient\n after a `safeTransfer`. This function MUST return the function selector,\n otherwise the caller will revert the transaction. The selector to be\n returned can be obtained as `this.onMockERC721Received.selector`. This\n function MAY throw to revert and reject the transfer.\n Note: the MockERC721 contract address is always the message sender.\n @param operator The address which called `safeTransferFrom` function\n @param from The address which previously owned the token\n @param tokenId The NFT identifier which is being transferred\n @param data Additional data with no specified format\n @return `bytes4(keccak256(\"onMockERC721Received(address,address,uint256,bytes)\"))`"
},
"functionSelector": "c9914843",
"id": 2021,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "onMockERC721Received",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 2017,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2010,
"mutability": "mutable",
"name": "operator",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2021,
"src": "3134:16:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 2009,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "3134:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 2012,
"mutability": "mutable",
"name": "from",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2021,
"src": "3152:12:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 2011,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "3152:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 2014,
"mutability": "mutable",
"name": "tokenId",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2021,
"src": "3166:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2013,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "3166:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 2016,
"mutability": "mutable",
"name": "data",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2021,
"src": "3183:17:13",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes"
},
"typeName": {
"id": 2015,
"name": "bytes",
"nodeType": "ElementaryTypeName",
"src": "3183:5:13",
"typeDescriptions": {
"typeIdentifier": "t_bytes_storage_ptr",
"typeString": "bytes"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "3133:68:13"
},
"returnParameters": {
"id": 2020,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2019,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2021,
"src": "3230:6:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
},
"typeName": {
"id": 2018,
"name": "bytes4",
"nodeType": "ElementaryTypeName",
"src": "3230:6:13",
"typeDescriptions": {
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "3229:8:13"
},
"scope": 2022,
"src": "3104:134:13",
"stateMutability": "nonpayable",
"virtual": true,
"visibility": "public"
}
],
"scope": 4171,
"src": "2193:1047:13"
},
{
"abstract": false,
"baseContracts": [],
"contractDependencies": [],
"contractKind": "library",
"documentation": {
"id": 2023,
"nodeType": "StructuredDocumentation",
"src": "3280:99:13",
"text": " @title SafeMath\n @dev Unsigned math operations with safety checks that revert on error"
},
"fullyImplemented": true,
"id": 2154,
"linearizedBaseContracts": [
2154
],
"name": "SafeMath",
"nodeType": "ContractDefinition",
"nodes": [
{
"body": {
"id": 2056,
"nodeType": "Block",
"src": "3551:354:13",
"statements": [
{
"condition": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 2035,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 2033,
"name": "a",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2026,
"src": "3782:1:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "==",
"rightExpression": {
"argumentTypes": null,
"hexValue": "30",
"id": 2034,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "3787:1:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
},
"src": "3782:6:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"falseBody": null,
"id": 2039,
"nodeType": "IfStatement",
"src": "3778:45:13",
"trueBody": {
"id": 2038,
"nodeType": "Block",
"src": "3790:33:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"hexValue": "30",
"id": 2036,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "3811:1:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
},
"functionReturnParameters": 2032,
"id": 2037,
"nodeType": "Return",
"src": "3804:8:13"
}
]
}
},
{
"assignments": [
2041
],
"declarations": [
{
"constant": false,
"id": 2041,
"mutability": "mutable",
"name": "c",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2056,
"src": "3833:9:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2040,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "3833:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 2045,
"initialValue": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 2044,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 2042,
"name": "a",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2026,
"src": "3845:1:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "*",
"rightExpression": {
"argumentTypes": null,
"id": 2043,
"name": "b",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2028,
"src": "3849:1:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "3845:5:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "3833:17:13"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 2051,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 2049,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 2047,
"name": "c",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2041,
"src": "3868:1:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "/",
"rightExpression": {
"argumentTypes": null,
"id": 2048,
"name": "a",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2026,
"src": "3872:1:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "3868:5:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "==",
"rightExpression": {
"argumentTypes": null,
"id": 2050,
"name": "b",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2028,
"src": "3877:1:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "3868:10:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 2046,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "3860:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 2052,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "3860:19:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2053,
"nodeType": "ExpressionStatement",
"src": "3860:19:13"
},
{
"expression": {
"argumentTypes": null,
"id": 2054,
"name": "c",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2041,
"src": "3897:1:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"functionReturnParameters": 2032,
"id": 2055,
"nodeType": "Return",
"src": "3890:8:13"
}
]
},
"documentation": {
"id": 2024,
"nodeType": "StructuredDocumentation",
"src": "3403:76:13",
"text": " @dev Multiplies two unsigned integers, reverts on overflow."
},
"id": 2057,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "mul",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 2029,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2026,
"mutability": "mutable",
"name": "a",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2057,
"src": "3497:9:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2025,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "3497:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 2028,
"mutability": "mutable",
"name": "b",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2057,
"src": "3508:9:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2027,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "3508:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "3496:22:13"
},
"returnParameters": {
"id": 2032,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2031,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2057,
"src": "3542:7:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2030,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "3542:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "3541:9:13"
},
"scope": 2154,
"src": "3484:421:13",
"stateMutability": "pure",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 2081,
"nodeType": "Block",
"src": "4100:229:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 2070,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 2068,
"name": "b",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2062,
"src": "4184:1:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": ">",
"rightExpression": {
"argumentTypes": null,
"hexValue": "30",
"id": 2069,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "4188:1:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
},
"src": "4184:5:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 2067,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "4176:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 2071,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "4176:14:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2072,
"nodeType": "ExpressionStatement",
"src": "4176:14:13"
},
{
"assignments": [
2074
],
"declarations": [
{
"constant": false,
"id": 2074,
"mutability": "mutable",
"name": "c",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2081,
"src": "4200:9:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2073,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "4200:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 2078,
"initialValue": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 2077,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 2075,
"name": "a",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2060,
"src": "4212:1:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "/",
"rightExpression": {
"argumentTypes": null,
"id": 2076,
"name": "b",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2062,
"src": "4216:1:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "4212:5:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "4200:17:13"
},
{
"expression": {
"argumentTypes": null,
"id": 2079,
"name": "c",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2074,
"src": "4321:1:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"functionReturnParameters": 2066,
"id": 2080,
"nodeType": "Return",
"src": "4314:8:13"
}
]
},
"documentation": {
"id": 2058,
"nodeType": "StructuredDocumentation",
"src": "3911:117:13",
"text": " @dev Integer division of two unsigned integers truncating the quotient, reverts on division by zero."
},
"id": 2082,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "div",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 2063,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2060,
"mutability": "mutable",
"name": "a",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2082,
"src": "4046:9:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2059,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "4046:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 2062,
"mutability": "mutable",
"name": "b",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2082,
"src": "4057:9:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2061,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "4057:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "4045:22:13"
},
"returnParameters": {
"id": 2066,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2065,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2082,
"src": "4091:7:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2064,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "4091:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "4090:9:13"
},
"scope": 2154,
"src": "4033:296:13",
"stateMutability": "pure",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 2106,
"nodeType": "Block",
"src": "4527:78:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 2095,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 2093,
"name": "b",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2087,
"src": "4545:1:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "<=",
"rightExpression": {
"argumentTypes": null,
"id": 2094,
"name": "a",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2085,
"src": "4550:1:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "4545:6:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 2092,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "4537:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 2096,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "4537:15:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2097,
"nodeType": "ExpressionStatement",
"src": "4537:15:13"
},
{
"assignments": [
2099
],
"declarations": [
{
"constant": false,
"id": 2099,
"mutability": "mutable",
"name": "c",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2106,
"src": "4562:9:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2098,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "4562:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 2103,
"initialValue": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 2102,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 2100,
"name": "a",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2085,
"src": "4574:1:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "-",
"rightExpression": {
"argumentTypes": null,
"id": 2101,
"name": "b",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2087,
"src": "4578:1:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "4574:5:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "4562:17:13"
},
{
"expression": {
"argumentTypes": null,
"id": 2104,
"name": "c",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2099,
"src": "4597:1:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"functionReturnParameters": 2091,
"id": 2105,
"nodeType": "Return",
"src": "4590:8:13"
}
]
},
"documentation": {
"id": 2083,
"nodeType": "StructuredDocumentation",
"src": "4335:120:13",
"text": " @dev Subtracts two unsigned integers, reverts on overflow (i.e. if subtrahend is greater than minuend)."
},
"id": 2107,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "sub",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 2088,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2085,
"mutability": "mutable",
"name": "a",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2107,
"src": "4473:9:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2084,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "4473:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 2087,
"mutability": "mutable",
"name": "b",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2107,
"src": "4484:9:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2086,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "4484:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "4472:22:13"
},
"returnParameters": {
"id": 2091,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2090,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2107,
"src": "4518:7:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2089,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "4518:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "4517:9:13"
},
"scope": 2154,
"src": "4460:145:13",
"stateMutability": "pure",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 2131,
"nodeType": "Block",
"src": "4753:78:13",
"statements": [
{
"assignments": [
2118
],
"declarations": [
{
"constant": false,
"id": 2118,
"mutability": "mutable",
"name": "c",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2131,
"src": "4763:9:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2117,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "4763:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 2122,
"initialValue": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 2121,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 2119,
"name": "a",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2110,
"src": "4775:1:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "+",
"rightExpression": {
"argumentTypes": null,
"id": 2120,
"name": "b",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2112,
"src": "4779:1:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "4775:5:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "4763:17:13"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 2126,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 2124,
"name": "c",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2118,
"src": "4798:1:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": ">=",
"rightExpression": {
"argumentTypes": null,
"id": 2125,
"name": "a",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2110,
"src": "4803:1:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "4798:6:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 2123,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "4790:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 2127,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "4790:15:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2128,
"nodeType": "ExpressionStatement",
"src": "4790:15:13"
},
{
"expression": {
"argumentTypes": null,
"id": 2129,
"name": "c",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2118,
"src": "4823:1:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"functionReturnParameters": 2116,
"id": 2130,
"nodeType": "Return",
"src": "4816:8:13"
}
]
},
"documentation": {
"id": 2108,
"nodeType": "StructuredDocumentation",
"src": "4611:70:13",
"text": " @dev Adds two unsigned integers, reverts on overflow."
},
"id": 2132,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "add",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 2113,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2110,
"mutability": "mutable",
"name": "a",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2132,
"src": "4699:9:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2109,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "4699:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 2112,
"mutability": "mutable",
"name": "b",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2132,
"src": "4710:9:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2111,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "4710:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "4698:22:13"
},
"returnParameters": {
"id": 2116,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2115,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2132,
"src": "4744:7:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2114,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "4744:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "4743:9:13"
},
"scope": 2154,
"src": "4686:145:13",
"stateMutability": "pure",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 2152,
"nodeType": "Block",
"src": "5050:54:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 2145,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 2143,
"name": "b",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2137,
"src": "5068:1:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "!=",
"rightExpression": {
"argumentTypes": null,
"hexValue": "30",
"id": 2144,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "5073:1:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
},
"src": "5068:6:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 2142,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "5060:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 2146,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "5060:15:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2147,
"nodeType": "ExpressionStatement",
"src": "5060:15:13"
},
{
"expression": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 2150,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 2148,
"name": "a",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2135,
"src": "5092:1:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "%",
"rightExpression": {
"argumentTypes": null,
"id": 2149,
"name": "b",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2137,
"src": "5096:1:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "5092:5:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"functionReturnParameters": 2141,
"id": 2151,
"nodeType": "Return",
"src": "5085:12:13"
}
]
},
"documentation": {
"id": 2133,
"nodeType": "StructuredDocumentation",
"src": "4837:141:13",
"text": " @dev Divides two unsigned integers and returns the remainder (unsigned integer modulo),\n reverts when dividing by zero."
},
"id": 2153,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "mod",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 2138,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2135,
"mutability": "mutable",
"name": "a",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2153,
"src": "4996:9:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2134,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "4996:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 2137,
"mutability": "mutable",
"name": "b",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2153,
"src": "5007:9:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2136,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "5007:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "4995:22:13"
},
"returnParameters": {
"id": 2141,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2140,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2153,
"src": "5041:7:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2139,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "5041:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "5040:9:13"
},
"scope": 2154,
"src": "4983:121:13",
"stateMutability": "pure",
"virtual": false,
"visibility": "internal"
}
],
"scope": 4171,
"src": "3380:1726:13"
},
{
"abstract": false,
"baseContracts": [],
"contractDependencies": [],
"contractKind": "library",
"documentation": {
"id": 2155,
"nodeType": "StructuredDocumentation",
"src": "5146:59:13",
"text": " Utility library of inline functions on addresses"
},
"fullyImplemented": true,
"id": 2173,
"linearizedBaseContracts": [
2173
],
"name": "Address",
"nodeType": "ContractDefinition",
"nodes": [
{
"body": {
"id": 2171,
"nodeType": "Block",
"src": "5650:550:13",
"statements": [
{
"assignments": [
2164
],
"declarations": [
{
"constant": false,
"id": 2164,
"mutability": "mutable",
"name": "size",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2171,
"src": "5660:12:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2163,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "5660:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 2165,
"initialValue": null,
"nodeType": "VariableDeclarationStatement",
"src": "5660:12:13"
},
{
"AST": {
"nodeType": "YulBlock",
"src": "6137:32:13",
"statements": [
{
"nodeType": "YulAssignment",
"src": "6139:28:13",
"value": {
"arguments": [
{
"name": "account",
"nodeType": "YulIdentifier",
"src": "6159:7:13"
}
],
"functionName": {
"name": "extcodesize",
"nodeType": "YulIdentifier",
"src": "6147:11:13"
},
"nodeType": "YulFunctionCall",
"src": "6147:20:13"
},
"variableNames": [
{
"name": "size",
"nodeType": "YulIdentifier",
"src": "6139:4:13"
}
]
}
]
},
"evmVersion": "constantinople",
"externalReferences": [
{
"declaration": 2158,
"isOffset": false,
"isSlot": false,
"src": "6159:7:13",
"valueSize": 1
},
{
"declaration": 2164,
"isOffset": false,
"isSlot": false,
"src": "6139:4:13",
"valueSize": 1
}
],
"id": 2166,
"nodeType": "InlineAssembly",
"src": "6128:41:13"
},
{
"expression": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 2169,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 2167,
"name": "size",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2164,
"src": "6185:4:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": ">",
"rightExpression": {
"argumentTypes": null,
"hexValue": "30",
"id": 2168,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "6192:1:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
},
"src": "6185:8:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"functionReturnParameters": 2162,
"id": 2170,
"nodeType": "Return",
"src": "6178:15:13"
}
]
},
"documentation": {
"id": 2156,
"nodeType": "StructuredDocumentation",
"src": "5228:351:13",
"text": " Returns whether the target address is a contract\n @dev This function will return false if invoked during the constructor of a contract,\n as the code is not actually created until after the constructor finishes.\n @param account address of the account to check\n @return whether the target address is a contract"
},
"id": 2172,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "isContract",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 2159,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2158,
"mutability": "mutable",
"name": "account",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2172,
"src": "5604:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 2157,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "5604:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "5603:17:13"
},
"returnParameters": {
"id": 2162,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2161,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2172,
"src": "5644:4:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 2160,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "5644:4:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "5643:6:13"
},
"scope": 2173,
"src": "5584:616:13",
"stateMutability": "view",
"virtual": false,
"visibility": "internal"
}
],
"scope": 4171,
"src": "5206:996:13"
},
{
"abstract": false,
"baseContracts": [
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 2175,
"name": "Initializable",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 74,
"src": "6376:13:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_Initializable_$74",
"typeString": "contract Initializable"
}
},
"id": 2176,
"nodeType": "InheritanceSpecifier",
"src": "6376:13:13"
},
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 2177,
"name": "IERC165",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 1976,
"src": "6391:7:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IERC165_$1976",
"typeString": "contract IERC165"
}
},
"id": 2178,
"nodeType": "InheritanceSpecifier",
"src": "6391:7:13"
}
],
"contractDependencies": [
74,
1976
],
"contractKind": "contract",
"documentation": {
"id": 2174,
"nodeType": "StructuredDocumentation",
"src": "6251:105:13",
"text": " @title ERC165\n @author Matt Condon (@shrugs)\n @dev Implements ERC165 using a lookup table."
},
"fullyImplemented": true,
"id": 2235,
"linearizedBaseContracts": [
2235,
1976,
74
],
"name": "ERC165",
"nodeType": "ContractDefinition",
"nodes": [
{
"constant": true,
"id": 2181,
"mutability": "constant",
"name": "_INTERFACE_ID_ERC165",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2235,
"src": "6405:57:13",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
},
"typeName": {
"id": 2179,
"name": "bytes4",
"nodeType": "ElementaryTypeName",
"src": "6405:6:13",
"typeDescriptions": {
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
}
},
"value": {
"argumentTypes": null,
"hexValue": "30783031666663396137",
"id": 2180,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "6452:10:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_33540519_by_1",
"typeString": "int_const 33540519"
},
"value": "0x01ffc9a7"
},
"visibility": "private"
},
{
"constant": false,
"documentation": {
"id": 2182,
"nodeType": "StructuredDocumentation",
"src": "6565:82:13",
"text": " @dev a mapping of interface id to whether or not it's supported"
},
"id": 2186,
"mutability": "mutable",
"name": "_supportedInterfaces",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2235,
"src": "6652:52:13",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_bytes4_$_t_bool_$",
"typeString": "mapping(bytes4 => bool)"
},
"typeName": {
"id": 2185,
"keyType": {
"id": 2183,
"name": "bytes4",
"nodeType": "ElementaryTypeName",
"src": "6660:6:13",
"typeDescriptions": {
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
}
},
"nodeType": "Mapping",
"src": "6652:23:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_bytes4_$_t_bool_$",
"typeString": "mapping(bytes4 => bool)"
},
"valueType": {
"id": 2184,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "6670:4:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
},
"value": null,
"visibility": "private"
},
{
"body": {
"id": 2196,
"nodeType": "Block",
"src": "6870:57:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 2193,
"name": "_INTERFACE_ID_ERC165",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2181,
"src": "6899:20:13",
"typeDescriptions": {
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
}
],
"id": 2192,
"name": "_registerInterface",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2230,
"src": "6880:18:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_bytes4_$returns$__$",
"typeString": "function (bytes4)"
}
},
"id": 2194,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "6880:40:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2195,
"nodeType": "ExpressionStatement",
"src": "6880:40:13"
}
]
},
"documentation": {
"id": 2187,
"nodeType": "StructuredDocumentation",
"src": "6711:106:13",
"text": " @dev A contract implementing SupportsInterfaceWithLookup\n implement ERC165 itself"
},
"functionSelector": "36fc697e",
"id": 2197,
"implemented": true,
"kind": "function",
"modifiers": [
{
"arguments": null,
"id": 2190,
"modifierName": {
"argumentTypes": null,
"id": 2189,
"name": "initializer",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 47,
"src": "6857:11:13",
"typeDescriptions": {
"typeIdentifier": "t_modifier$__$",
"typeString": "modifier ()"
}
},
"nodeType": "ModifierInvocation",
"src": "6857:11:13"
}
],
"name": "initializeERC165",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 2188,
"nodeType": "ParameterList",
"parameters": [],
"src": "6847:2:13"
},
"returnParameters": {
"id": 2191,
"nodeType": "ParameterList",
"parameters": [],
"src": "6870:0:13"
},
"scope": 2235,
"src": "6822:105:13",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
{
"baseFunctions": [
1975
],
"body": {
"id": 2210,
"nodeType": "Block",
"src": "7101:57:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 2206,
"name": "_supportedInterfaces",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2186,
"src": "7118:20:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_bytes4_$_t_bool_$",
"typeString": "mapping(bytes4 => bool)"
}
},
"id": 2208,
"indexExpression": {
"argumentTypes": null,
"id": 2207,
"name": "interfaceId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2200,
"src": "7139:11:13",
"typeDescriptions": {
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "7118:33:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"functionReturnParameters": 2205,
"id": 2209,
"nodeType": "Return",
"src": "7111:40:13"
}
]
},
"documentation": {
"id": 2198,
"nodeType": "StructuredDocumentation",
"src": "6933:80:13",
"text": " @dev implement supportsInterface(bytes4) using a lookup table"
},
"functionSelector": "01ffc9a7",
"id": 2211,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "supportsInterface",
"nodeType": "FunctionDefinition",
"overrides": {
"id": 2202,
"nodeType": "OverrideSpecifier",
"overrides": [],
"src": "7077:8:13"
},
"parameters": {
"id": 2201,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2200,
"mutability": "mutable",
"name": "interfaceId",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2211,
"src": "7045:18:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
},
"typeName": {
"id": 2199,
"name": "bytes4",
"nodeType": "ElementaryTypeName",
"src": "7045:6:13",
"typeDescriptions": {
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "7044:20:13"
},
"returnParameters": {
"id": 2205,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2204,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2211,
"src": "7095:4:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 2203,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "7095:4:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "7094:6:13"
},
"scope": 2235,
"src": "7018:140:13",
"stateMutability": "view",
"virtual": false,
"visibility": "public"
},
{
"body": {
"id": 2229,
"nodeType": "Block",
"src": "7294:101:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
},
"id": 2220,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 2218,
"name": "interfaceId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2214,
"src": "7312:11:13",
"typeDescriptions": {
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
}
},
"nodeType": "BinaryOperation",
"operator": "!=",
"rightExpression": {
"argumentTypes": null,
"hexValue": "30786666666666666666",
"id": 2219,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "7327:10:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_4294967295_by_1",
"typeString": "int_const 4294967295"
},
"value": "0xffffffff"
},
"src": "7312:25:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 2217,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "7304:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 2221,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "7304:34:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2222,
"nodeType": "ExpressionStatement",
"src": "7304:34:13"
},
{
"expression": {
"argumentTypes": null,
"id": 2227,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 2223,
"name": "_supportedInterfaces",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2186,
"src": "7348:20:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_bytes4_$_t_bool_$",
"typeString": "mapping(bytes4 => bool)"
}
},
"id": 2225,
"indexExpression": {
"argumentTypes": null,
"id": 2224,
"name": "interfaceId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2214,
"src": "7369:11:13",
"typeDescriptions": {
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": true,
"nodeType": "IndexAccess",
"src": "7348:33:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"hexValue": "74727565",
"id": 2226,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "bool",
"lValueRequested": false,
"nodeType": "Literal",
"src": "7384:4:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"value": "true"
},
"src": "7348:40:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"id": 2228,
"nodeType": "ExpressionStatement",
"src": "7348:40:13"
}
]
},
"documentation": {
"id": 2212,
"nodeType": "StructuredDocumentation",
"src": "7164:68:13",
"text": " @dev internal method for registering an interface"
},
"id": 2230,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "_registerInterface",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 2215,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2214,
"mutability": "mutable",
"name": "interfaceId",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2230,
"src": "7265:18:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
},
"typeName": {
"id": 2213,
"name": "bytes4",
"nodeType": "ElementaryTypeName",
"src": "7265:6:13",
"typeDescriptions": {
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "7264:20:13"
},
"returnParameters": {
"id": 2216,
"nodeType": "ParameterList",
"parameters": [],
"src": "7294:0:13"
},
"scope": 2235,
"src": "7237:158:13",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "internal"
},
{
"constant": false,
"id": 2234,
"mutability": "mutable",
"name": "______gap",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2235,
"src": "7401:29:13",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$50_storage",
"typeString": "uint256[50]"
},
"typeName": {
"baseType": {
"id": 2231,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "7401:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 2233,
"length": {
"argumentTypes": null,
"hexValue": "3530",
"id": 2232,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "7409:2:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_50_by_1",
"typeString": "int_const 50"
},
"value": "50"
},
"nodeType": "ArrayTypeName",
"src": "7401:11:13",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$50_storage_ptr",
"typeString": "uint256[50]"
}
},
"value": null,
"visibility": "private"
}
],
"scope": 4171,
"src": "6357:1076:13"
},
{
"abstract": false,
"baseContracts": [
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 2237,
"name": "Initializable",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 74,
"src": "7661:13:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_Initializable_$74",
"typeString": "contract Initializable"
}
},
"id": 2238,
"nodeType": "InheritanceSpecifier",
"src": "7661:13:13"
},
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 2239,
"name": "ERC165",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 2235,
"src": "7676:6:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_ERC165_$2235",
"typeString": "contract ERC165"
}
},
"id": 2240,
"nodeType": "InheritanceSpecifier",
"src": "7676:6:13"
},
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 2241,
"name": "IMockERC721",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 2006,
"src": "7684:11:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IMockERC721_$2006",
"typeString": "contract IMockERC721"
}
},
"id": 2242,
"nodeType": "InheritanceSpecifier",
"src": "7684:11:13"
}
],
"contractDependencies": [
74,
1976,
2006,
2235
],
"contractKind": "contract",
"documentation": {
"id": 2236,
"nodeType": "StructuredDocumentation",
"src": "7487:150:13",
"text": " @title MockERC721 Non-Fungible Token Standard basic implementation\n @dev see https://github.com/ethereum/EIPs/blob/master/EIPS/eip-721.md"
},
"fullyImplemented": true,
"id": 2838,
"linearizedBaseContracts": [
2838,
2006,
2235,
1976,
74
],
"name": "MockERC721",
"nodeType": "ContractDefinition",
"nodes": [
{
"id": 2245,
"libraryName": {
"contractScope": null,
"id": 2243,
"name": "SafeMath",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 2154,
"src": "7708:8:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_SafeMath_$2154",
"typeString": "library SafeMath"
}
},
"nodeType": "UsingForDirective",
"src": "7702:27:13",
"typeName": {
"id": 2244,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "7721:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
},
{
"id": 2248,
"libraryName": {
"contractScope": null,
"id": 2246,
"name": "Address",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 2173,
"src": "7740:7:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_Address_$2173",
"typeString": "library Address"
}
},
"nodeType": "UsingForDirective",
"src": "7734:26:13",
"typeName": {
"id": 2247,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "7752:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
},
{
"constant": true,
"id": 2251,
"mutability": "constant",
"name": "_MockERC721_RECEIVED",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2838,
"src": "7950:57:13",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
},
"typeName": {
"id": 2249,
"name": "bytes4",
"nodeType": "ElementaryTypeName",
"src": "7950:6:13",
"typeDescriptions": {
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
}
},
"value": {
"argumentTypes": null,
"hexValue": "30783135306237613032",
"id": 2250,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "7997:10:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_353073666_by_1",
"typeString": "int_const 353073666"
},
"value": "0x150b7a02"
},
"visibility": "private"
},
{
"constant": false,
"id": 2255,
"mutability": "mutable",
"name": "_tokenOwner",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2838,
"src": "8052:48:13",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_uint256_$_t_address_$",
"typeString": "mapping(uint256 => address)"
},
"typeName": {
"id": 2254,
"keyType": {
"id": 2252,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "8061:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "Mapping",
"src": "8052:28:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_uint256_$_t_address_$",
"typeString": "mapping(uint256 => address)"
},
"valueType": {
"id": 2253,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "8072:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
},
"value": null,
"visibility": "private"
},
{
"constant": false,
"id": 2259,
"mutability": "mutable",
"name": "_tokenApprovals",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2838,
"src": "8156:52:13",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_uint256_$_t_address_$",
"typeString": "mapping(uint256 => address)"
},
"typeName": {
"id": 2258,
"keyType": {
"id": 2256,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "8165:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "Mapping",
"src": "8156:28:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_uint256_$_t_address_$",
"typeString": "mapping(uint256 => address)"
},
"valueType": {
"id": 2257,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "8176:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
},
"value": null,
"visibility": "private"
},
{
"constant": false,
"id": 2263,
"mutability": "mutable",
"name": "_ownedTokensCount",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2838,
"src": "8266:54:13",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
"typeString": "mapping(address => uint256)"
},
"typeName": {
"id": 2262,
"keyType": {
"id": 2260,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "8275:7:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "Mapping",
"src": "8266:28:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
"typeString": "mapping(address => uint256)"
},
"valueType": {
"id": 2261,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "8286:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
},
"value": null,
"visibility": "private"
},
{
"constant": false,
"id": 2269,
"mutability": "mutable",
"name": "_operatorApprovals",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2838,
"src": "8375:73:13",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_bool_$_$",
"typeString": "mapping(address => mapping(address => bool))"
},
"typeName": {
"id": 2268,
"keyType": {
"id": 2264,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "8384:7:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "Mapping",
"src": "8375:46:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_bool_$_$",
"typeString": "mapping(address => mapping(address => bool))"
},
"valueType": {
"id": 2267,
"keyType": {
"id": 2265,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "8404:7:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "Mapping",
"src": "8395:25:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_bool_$",
"typeString": "mapping(address => bool)"
},
"valueType": {
"id": 2266,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "8415:4:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
}
},
"value": null,
"visibility": "private"
},
{
"constant": true,
"id": 2272,
"mutability": "constant",
"name": "_INTERFACE_ID_MockERC721",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2838,
"src": "8455:61:13",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
},
"typeName": {
"id": 2270,
"name": "bytes4",
"nodeType": "ElementaryTypeName",
"src": "8455:6:13",
"typeDescriptions": {
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
}
},
"value": {
"argumentTypes": null,
"hexValue": "30783830616335386364",
"id": 2271,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "8506:10:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_2158778573_by_1",
"typeString": "int_const 2158778573"
},
"value": "0x80ac58cd"
},
"visibility": "private"
},
{
"body": {
"id": 2286,
"nodeType": "Block",
"src": "9189:178:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [],
"expression": {
"argumentTypes": [],
"expression": {
"argumentTypes": null,
"id": 2277,
"name": "ERC165",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2235,
"src": "9199:6:13",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_contract$_ERC165_$2235_$",
"typeString": "type(contract ERC165)"
}
},
"id": 2279,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "initializeERC165",
"nodeType": "MemberAccess",
"referencedDeclaration": 2197,
"src": "9199:23:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$__$returns$__$",
"typeString": "function ()"
}
},
"id": 2280,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "9199:25:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2281,
"nodeType": "ExpressionStatement",
"src": "9199:25:13"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 2283,
"name": "_INTERFACE_ID_MockERC721",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2272,
"src": "9335:24:13",
"typeDescriptions": {
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
}
],
"id": 2282,
"name": "_registerInterface",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2230,
"src": "9316:18:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_bytes4_$returns$__$",
"typeString": "function (bytes4)"
}
},
"id": 2284,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "9316:44:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2285,
"nodeType": "ExpressionStatement",
"src": "9316:44:13"
}
]
},
"documentation": null,
"functionSelector": "8129fc1c",
"id": 2287,
"implemented": true,
"kind": "function",
"modifiers": [
{
"arguments": null,
"id": 2275,
"modifierName": {
"argumentTypes": null,
"id": 2274,
"name": "initializer",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 47,
"src": "9169:11:13",
"typeDescriptions": {
"typeIdentifier": "t_modifier$__$",
"typeString": "modifier ()"
}
},
"nodeType": "ModifierInvocation",
"src": "9169:11:13"
}
],
"name": "initialize",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 2273,
"nodeType": "ParameterList",
"parameters": [],
"src": "9159:2:13"
},
"returnParameters": {
"id": 2276,
"nodeType": "ParameterList",
"parameters": [],
"src": "9189:0:13"
},
"scope": 2838,
"src": "9140:227:13",
"stateMutability": "nonpayable",
"virtual": true,
"visibility": "public"
},
{
"body": {
"id": 2296,
"nodeType": "Block",
"src": "9451:67:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 2293,
"name": "_INTERFACE_ID_MockERC721",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2272,
"src": "9486:24:13",
"typeDescriptions": {
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
}
],
"id": 2292,
"name": "supportsInterface",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2211,
"src": "9468:17:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$_t_bytes4_$returns$_t_bool_$",
"typeString": "function (bytes4) view returns (bool)"
}
},
"id": 2294,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "9468:43:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"functionReturnParameters": 2291,
"id": 2295,
"nodeType": "Return",
"src": "9461:50:13"
}
]
},
"documentation": null,
"id": 2297,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "_hasBeenInitializedMockERC721",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 2288,
"nodeType": "ParameterList",
"parameters": [],
"src": "9411:2:13"
},
"returnParameters": {
"id": 2291,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2290,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2297,
"src": "9445:4:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 2289,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "9445:4:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "9444:6:13"
},
"scope": 2838,
"src": "9373:145:13",
"stateMutability": "view",
"virtual": true,
"visibility": "internal"
},
{
"body": {
"id": 2318,
"nodeType": "Block",
"src": "9785:86:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"id": 2311,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 2306,
"name": "owner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2300,
"src": "9803:5:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "BinaryOperation",
"operator": "!=",
"rightExpression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"hexValue": "30",
"id": 2309,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "9820:1:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
}
],
"id": 2308,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "ElementaryTypeNameExpression",
"src": "9812:7:13",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_address_$",
"typeString": "type(address)"
},
"typeName": {
"id": 2307,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "9812:7:13",
"typeDescriptions": {
"typeIdentifier": null,
"typeString": null
}
}
},
"id": 2310,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "9812:10:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
}
},
"src": "9803:19:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 2305,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "9795:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 2312,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "9795:28:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2313,
"nodeType": "ExpressionStatement",
"src": "9795:28:13"
},
{
"expression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 2314,
"name": "_ownedTokensCount",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2263,
"src": "9840:17:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
"typeString": "mapping(address => uint256)"
}
},
"id": 2316,
"indexExpression": {
"argumentTypes": null,
"id": 2315,
"name": "owner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2300,
"src": "9858:5:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "9840:24:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"functionReturnParameters": 2304,
"id": 2317,
"nodeType": "Return",
"src": "9833:31:13"
}
]
},
"documentation": {
"id": 2298,
"nodeType": "StructuredDocumentation",
"src": "9524:192:13",
"text": " @dev Gets the balance of the specified address\n @param owner address to query the balance of\n @return uint256 representing the amount owned by the passed address"
},
"functionSelector": "70a08231",
"id": 2319,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "balanceOf",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 2301,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2300,
"mutability": "mutable",
"name": "owner",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2319,
"src": "9740:13:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 2299,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "9740:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "9739:15:13"
},
"returnParameters": {
"id": 2304,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2303,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2319,
"src": "9776:7:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2302,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "9776:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "9775:9:13"
},
"scope": 2838,
"src": "9721:150:13",
"stateMutability": "view",
"virtual": false,
"visibility": "public"
},
{
"body": {
"id": 2344,
"nodeType": "Block",
"src": "10159:113:13",
"statements": [
{
"assignments": [
2328
],
"declarations": [
{
"constant": false,
"id": 2328,
"mutability": "mutable",
"name": "owner",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2344,
"src": "10169:13:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 2327,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "10169:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 2332,
"initialValue": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 2329,
"name": "_tokenOwner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2255,
"src": "10185:11:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_uint256_$_t_address_$",
"typeString": "mapping(uint256 => address)"
}
},
"id": 2331,
"indexExpression": {
"argumentTypes": null,
"id": 2330,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2322,
"src": "10197:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "10185:20:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "10169:36:13"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"id": 2339,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 2334,
"name": "owner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2328,
"src": "10223:5:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "BinaryOperation",
"operator": "!=",
"rightExpression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"hexValue": "30",
"id": 2337,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "10240:1:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
}
],
"id": 2336,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "ElementaryTypeNameExpression",
"src": "10232:7:13",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_address_$",
"typeString": "type(address)"
},
"typeName": {
"id": 2335,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "10232:7:13",
"typeDescriptions": {
"typeIdentifier": null,
"typeString": null
}
}
},
"id": 2338,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "10232:10:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
}
},
"src": "10223:19:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 2333,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "10215:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 2340,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "10215:28:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2341,
"nodeType": "ExpressionStatement",
"src": "10215:28:13"
},
{
"expression": {
"argumentTypes": null,
"id": 2342,
"name": "owner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2328,
"src": "10260:5:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"functionReturnParameters": 2326,
"id": 2343,
"nodeType": "Return",
"src": "10253:12:13"
}
]
},
"documentation": {
"id": 2320,
"nodeType": "StructuredDocumentation",
"src": "9877:213:13",
"text": " @dev Gets the owner of the specified token ID\n @param tokenId uint256 ID of the token to query the owner of\n @return owner address currently marked as the owner of the given token ID"
},
"functionSelector": "6352211e",
"id": 2345,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "ownerOf",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 2323,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2322,
"mutability": "mutable",
"name": "tokenId",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2345,
"src": "10112:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2321,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "10112:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "10111:17:13"
},
"returnParameters": {
"id": 2326,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2325,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2345,
"src": "10150:7:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 2324,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "10150:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "10149:9:13"
},
"scope": 2838,
"src": "10095:177:13",
"stateMutability": "view",
"virtual": false,
"visibility": "public"
},
{
"body": {
"id": 2390,
"nodeType": "Block",
"src": "10756:239:13",
"statements": [
{
"assignments": [
2354
],
"declarations": [
{
"constant": false,
"id": 2354,
"mutability": "mutable",
"name": "owner",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2390,
"src": "10766:13:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 2353,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "10766:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 2358,
"initialValue": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 2356,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2350,
"src": "10790:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"id": 2355,
"name": "ownerOf",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2345,
"src": "10782:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$_t_uint256_$returns$_t_address_$",
"typeString": "function (uint256) view returns (address)"
}
},
"id": 2357,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "10782:16:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "10766:32:13"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"id": 2362,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 2360,
"name": "to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2348,
"src": "10816:2:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "BinaryOperation",
"operator": "!=",
"rightExpression": {
"argumentTypes": null,
"id": 2361,
"name": "owner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2354,
"src": "10822:5:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"src": "10816:11:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 2359,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "10808:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 2363,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "10808:20:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2364,
"nodeType": "ExpressionStatement",
"src": "10808:20:13"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"id": 2375,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"id": 2369,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 2366,
"name": "msg",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": -15,
"src": "10846:3:13",
"typeDescriptions": {
"typeIdentifier": "t_magic_message",
"typeString": "msg"
}
},
"id": 2367,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "sender",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "10846:10:13",
"typeDescriptions": {
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
}
},
"nodeType": "BinaryOperation",
"operator": "==",
"rightExpression": {
"argumentTypes": null,
"id": 2368,
"name": "owner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2354,
"src": "10860:5:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"src": "10846:19:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"nodeType": "BinaryOperation",
"operator": "||",
"rightExpression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 2371,
"name": "owner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2354,
"src": "10886:5:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 2372,
"name": "msg",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": -15,
"src": "10893:3:13",
"typeDescriptions": {
"typeIdentifier": "t_magic_message",
"typeString": "msg"
}
},
"id": 2373,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "sender",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "10893:10:13",
"typeDescriptions": {
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
}
],
"id": 2370,
"name": "isApprovedForAll",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2459,
"src": "10869:16:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$_t_address_$_t_address_$returns$_t_bool_$",
"typeString": "function (address,address) view returns (bool)"
}
},
"id": 2374,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "10869:35:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"src": "10846:58:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 2365,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "10838:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 2376,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "10838:67:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2377,
"nodeType": "ExpressionStatement",
"src": "10838:67:13"
},
{
"expression": {
"argumentTypes": null,
"id": 2382,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 2378,
"name": "_tokenApprovals",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2259,
"src": "10916:15:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_uint256_$_t_address_$",
"typeString": "mapping(uint256 => address)"
}
},
"id": 2380,
"indexExpression": {
"argumentTypes": null,
"id": 2379,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2350,
"src": "10932:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": true,
"nodeType": "IndexAccess",
"src": "10916:24:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"id": 2381,
"name": "to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2348,
"src": "10943:2:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"src": "10916:29:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"id": 2383,
"nodeType": "ExpressionStatement",
"src": "10916:29:13"
},
{
"eventCall": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 2385,
"name": "owner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2354,
"src": "10969:5:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 2386,
"name": "to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2348,
"src": "10976:2:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 2387,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2350,
"src": "10980:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"id": 2384,
"name": "Approval",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1997,
"src": "10960:8:13",
"typeDescriptions": {
"typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$",
"typeString": "function (address,address,uint256)"
}
},
"id": 2388,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "10960:28:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2389,
"nodeType": "EmitStatement",
"src": "10955:33:13"
}
]
},
"documentation": {
"id": 2346,
"nodeType": "StructuredDocumentation",
"src": "10278:410:13",
"text": " @dev Approves another address to transfer the given token ID\n The zero address indicates there is no approved address.\n There can only be one approved address per token at a given time.\n Can only be called by the token owner or an approved operator.\n @param to address to be approved for the given token ID\n @param tokenId uint256 ID of the token to be approved"
},
"functionSelector": "aec6e4ea",
"id": 2391,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "approveMockERC721",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 2351,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2348,
"mutability": "mutable",
"name": "to",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2391,
"src": "10720:10:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 2347,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "10720:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 2350,
"mutability": "mutable",
"name": "tokenId",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2391,
"src": "10732:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2349,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "10732:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "10719:29:13"
},
"returnParameters": {
"id": 2352,
"nodeType": "ParameterList",
"parameters": [],
"src": "10756:0:13"
},
"scope": 2838,
"src": "10693:302:13",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
{
"body": {
"id": 2409,
"nodeType": "Block",
"src": "11349:83:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 2401,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2394,
"src": "11375:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"id": 2400,
"name": "_exists",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2552,
"src": "11367:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$_t_uint256_$returns$_t_bool_$",
"typeString": "function (uint256) view returns (bool)"
}
},
"id": 2402,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "11367:16:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 2399,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "11359:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 2403,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "11359:25:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2404,
"nodeType": "ExpressionStatement",
"src": "11359:25:13"
},
{
"expression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 2405,
"name": "_tokenApprovals",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2259,
"src": "11401:15:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_uint256_$_t_address_$",
"typeString": "mapping(uint256 => address)"
}
},
"id": 2407,
"indexExpression": {
"argumentTypes": null,
"id": 2406,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2394,
"src": "11417:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "11401:24:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"functionReturnParameters": 2398,
"id": 2408,
"nodeType": "Return",
"src": "11394:31:13"
}
]
},
"documentation": {
"id": 2392,
"nodeType": "StructuredDocumentation",
"src": "11001:274:13",
"text": " @dev Gets the approved address for a token ID, or zero if no address set\n Reverts if the token ID does not exist.\n @param tokenId uint256 ID of the token to query the approval of\n @return address currently approved for the given token ID"
},
"functionSelector": "081812fc",
"id": 2410,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "getApproved",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 2395,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2394,
"mutability": "mutable",
"name": "tokenId",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2410,
"src": "11301:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2393,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "11301:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "11300:17:13"
},
"returnParameters": {
"id": 2398,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2397,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2410,
"src": "11340:7:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 2396,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "11340:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "11339:9:13"
},
"scope": 2838,
"src": "11280:152:13",
"stateMutability": "view",
"virtual": false,
"visibility": "public"
},
{
"body": {
"id": 2441,
"nodeType": "Block",
"src": "11795:152:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"id": 2422,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 2419,
"name": "to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2413,
"src": "11813:2:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "BinaryOperation",
"operator": "!=",
"rightExpression": {
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 2420,
"name": "msg",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": -15,
"src": "11819:3:13",
"typeDescriptions": {
"typeIdentifier": "t_magic_message",
"typeString": "msg"
}
},
"id": 2421,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "sender",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "11819:10:13",
"typeDescriptions": {
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
}
},
"src": "11813:16:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 2418,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "11805:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 2423,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "11805:25:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2424,
"nodeType": "ExpressionStatement",
"src": "11805:25:13"
},
{
"expression": {
"argumentTypes": null,
"id": 2432,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 2425,
"name": "_operatorApprovals",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2269,
"src": "11840:18:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_bool_$_$",
"typeString": "mapping(address => mapping(address => bool))"
}
},
"id": 2429,
"indexExpression": {
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 2426,
"name": "msg",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": -15,
"src": "11859:3:13",
"typeDescriptions": {
"typeIdentifier": "t_magic_message",
"typeString": "msg"
}
},
"id": 2427,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "sender",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "11859:10:13",
"typeDescriptions": {
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "11840:30:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_bool_$",
"typeString": "mapping(address => bool)"
}
},
"id": 2430,
"indexExpression": {
"argumentTypes": null,
"id": 2428,
"name": "to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2413,
"src": "11871:2:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": true,
"nodeType": "IndexAccess",
"src": "11840:34:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"id": 2431,
"name": "approved",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2415,
"src": "11877:8:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"src": "11840:45:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"id": 2433,
"nodeType": "ExpressionStatement",
"src": "11840:45:13"
},
{
"eventCall": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 2435,
"name": "msg",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": -15,
"src": "11915:3:13",
"typeDescriptions": {
"typeIdentifier": "t_magic_message",
"typeString": "msg"
}
},
"id": 2436,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "sender",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "11915:10:13",
"typeDescriptions": {
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
}
},
{
"argumentTypes": null,
"id": 2437,
"name": "to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2413,
"src": "11927:2:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 2438,
"name": "approved",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2415,
"src": "11931:8:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
},
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 2434,
"name": "ApprovalForAll",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2005,
"src": "11900:14:13",
"typeDescriptions": {
"typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_bool_$returns$__$",
"typeString": "function (address,address,bool)"
}
},
"id": 2439,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "11900:40:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2440,
"nodeType": "EmitStatement",
"src": "11895:45:13"
}
]
},
"documentation": {
"id": 2411,
"nodeType": "StructuredDocumentation",
"src": "11438:281:13",
"text": " @dev Sets or unsets the approval of a given operator\n An operator is allowed to transfer all tokens of the sender on their behalf\n @param to operator address to set the approval\n @param approved representing the status of the approval to be set"
},
"functionSelector": "da71878c",
"id": 2442,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "setApprovalForAllMockERC721",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 2416,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2413,
"mutability": "mutable",
"name": "to",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2442,
"src": "11761:10:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 2412,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "11761:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 2415,
"mutability": "mutable",
"name": "approved",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2442,
"src": "11773:13:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 2414,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "11773:4:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "11760:27:13"
},
"returnParameters": {
"id": 2417,
"nodeType": "ParameterList",
"parameters": [],
"src": "11795:0:13"
},
"scope": 2838,
"src": "11724:223:13",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
{
"body": {
"id": 2458,
"nodeType": "Block",
"src": "12355:59:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 2452,
"name": "_operatorApprovals",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2269,
"src": "12372:18:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_bool_$_$",
"typeString": "mapping(address => mapping(address => bool))"
}
},
"id": 2454,
"indexExpression": {
"argumentTypes": null,
"id": 2453,
"name": "owner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2445,
"src": "12391:5:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "12372:25:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_bool_$",
"typeString": "mapping(address => bool)"
}
},
"id": 2456,
"indexExpression": {
"argumentTypes": null,
"id": 2455,
"name": "operator",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2447,
"src": "12398:8:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "12372:35:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"functionReturnParameters": 2451,
"id": 2457,
"nodeType": "Return",
"src": "12365:42:13"
}
]
},
"documentation": {
"id": 2443,
"nodeType": "StructuredDocumentation",
"src": "11953:310:13",
"text": " @dev Tells whether an operator is approved by a given owner\n @param owner owner address which you want to query the approval of\n @param operator operator address which you want to query the approval of\n @return bool whether the given operator is approved by the given owner"
},
"functionSelector": "e985e9c5",
"id": 2459,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "isApprovedForAll",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 2448,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2445,
"mutability": "mutable",
"name": "owner",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2459,
"src": "12294:13:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 2444,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "12294:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 2447,
"mutability": "mutable",
"name": "operator",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2459,
"src": "12309:16:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 2446,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "12309:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "12293:33:13"
},
"returnParameters": {
"id": 2451,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2450,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2459,
"src": "12349:4:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 2449,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "12349:4:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "12348:6:13"
},
"scope": 2838,
"src": "12268:146:13",
"stateMutability": "view",
"virtual": false,
"visibility": "public"
},
{
"body": {
"id": 2483,
"nodeType": "Block",
"src": "12937:118:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 2471,
"name": "msg",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": -15,
"src": "12974:3:13",
"typeDescriptions": {
"typeIdentifier": "t_magic_message",
"typeString": "msg"
}
},
"id": 2472,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "sender",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "12974:10:13",
"typeDescriptions": {
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
}
},
{
"argumentTypes": null,
"id": 2473,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2466,
"src": "12986:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
},
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"id": 2470,
"name": "_isApprovedOrOwner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2585,
"src": "12955:18:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$_t_address_$_t_uint256_$returns$_t_bool_$",
"typeString": "function (address,uint256) view returns (bool)"
}
},
"id": 2474,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "12955:39:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 2469,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "12947:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 2475,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "12947:48:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2476,
"nodeType": "ExpressionStatement",
"src": "12947:48:13"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 2478,
"name": "from",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2462,
"src": "13030:4:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 2479,
"name": "to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2464,
"src": "13036:2:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 2480,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2466,
"src": "13040:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"id": 2477,
"name": "_transferFromMockERC721",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2766,
"src": "13006:23:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$",
"typeString": "function (address,address,uint256)"
}
},
"id": 2481,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "13006:42:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2482,
"nodeType": "ExpressionStatement",
"src": "13006:42:13"
}
]
},
"documentation": {
"id": 2460,
"nodeType": "StructuredDocumentation",
"src": "12420:422:13",
"text": " @dev Transfers the ownership of a given token ID to another address\n Usage of this method is discouraged, use `safeTransferFrom` whenever possible\n Requires the msg sender to be the owner, approved, or operator\n @param from current owner of the token\n @param to address to receive the ownership of the given token ID\n @param tokenId uint256 ID of the token to be transferred"
},
"functionSelector": "630ca90b",
"id": 2484,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "transferFromMockERC721",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 2467,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2462,
"mutability": "mutable",
"name": "from",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2484,
"src": "12879:12:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 2461,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "12879:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 2464,
"mutability": "mutable",
"name": "to",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2484,
"src": "12893:10:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 2463,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "12893:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 2466,
"mutability": "mutable",
"name": "tokenId",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2484,
"src": "12905:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2465,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "12905:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "12878:43:13"
},
"returnParameters": {
"id": 2468,
"nodeType": "ParameterList",
"parameters": [],
"src": "12937:0:13"
},
"scope": 2838,
"src": "12847:208:13",
"stateMutability": "nonpayable",
"virtual": true,
"visibility": "public"
},
{
"body": {
"id": 2501,
"nodeType": "Block",
"src": "13779:56:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 2495,
"name": "from",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2487,
"src": "13806:4:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 2496,
"name": "to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2489,
"src": "13812:2:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 2497,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2491,
"src": "13816:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
{
"argumentTypes": null,
"hexValue": "",
"id": 2498,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "13825:2:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_c5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470",
"typeString": "literal_string \"\""
},
"value": ""
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
{
"typeIdentifier": "t_stringliteral_c5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470",
"typeString": "literal_string \"\""
}
],
"id": 2494,
"name": "safeTransferFrom",
"nodeType": "Identifier",
"overloadedDeclarations": [
2502,
2530
],
"referencedDeclaration": 2530,
"src": "13789:16:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_address_$_t_uint256_$_t_bytes_memory_ptr_$returns$__$",
"typeString": "function (address,address,uint256,bytes memory)"
}
},
"id": 2499,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "13789:39:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2500,
"nodeType": "ExpressionStatement",
"src": "13789:39:13"
}
]
},
"documentation": {
"id": 2485,
"nodeType": "StructuredDocumentation",
"src": "13061:636:13",
"text": " @dev Safely transfers the ownership of a given token ID to another address\n If the target address is a contract, it must implement `onMockERC721Received`,\n which is called upon a safe transfer, and return the magic value\n `bytes4(keccak256(\"onMockERC721Received(address,address,uint256,bytes)\"))`; otherwise,\n the transfer is reverted.\n Requires the msg sender to be the owner, approved, or operator\n @param from current owner of the token\n @param to address to receive the ownership of the given token ID\n @param tokenId uint256 ID of the token to be transferred"
},
"functionSelector": "42842e0e",
"id": 2502,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "safeTransferFrom",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 2492,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2487,
"mutability": "mutable",
"name": "from",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2502,
"src": "13728:12:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 2486,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "13728:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 2489,
"mutability": "mutable",
"name": "to",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2502,
"src": "13742:10:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 2488,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "13742:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 2491,
"mutability": "mutable",
"name": "tokenId",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2502,
"src": "13754:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2490,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "13754:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "13727:43:13"
},
"returnParameters": {
"id": 2493,
"nodeType": "ParameterList",
"parameters": [],
"src": "13779:0:13"
},
"scope": 2838,
"src": "13702:133:13",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
{
"body": {
"id": 2529,
"nodeType": "Block",
"src": "14645:129:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 2515,
"name": "from",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2505,
"src": "14678:4:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 2516,
"name": "to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2507,
"src": "14684:2:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 2517,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2509,
"src": "14688:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"id": 2514,
"name": "transferFromMockERC721",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2484,
"src": "14655:22:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$",
"typeString": "function (address,address,uint256)"
}
},
"id": 2518,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "14655:41:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2519,
"nodeType": "ExpressionStatement",
"src": "14655:41:13"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 2522,
"name": "from",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2505,
"src": "14741:4:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 2523,
"name": "to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2507,
"src": "14747:2:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 2524,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2509,
"src": "14751:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
{
"argumentTypes": null,
"id": 2525,
"name": "_data",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2511,
"src": "14760:5:13",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
{
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
],
"id": 2521,
"name": "_checkOnMockERC721Received",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2807,
"src": "14714:26:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_address_$_t_uint256_$_t_bytes_memory_ptr_$returns$_t_bool_$",
"typeString": "function (address,address,uint256,bytes memory) returns (bool)"
}
},
"id": 2526,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "14714:52:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 2520,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "14706:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 2527,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "14706:61:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2528,
"nodeType": "ExpressionStatement",
"src": "14706:61:13"
}
]
},
"documentation": {
"id": 2503,
"nodeType": "StructuredDocumentation",
"src": "13841:702:13",
"text": " @dev Safely transfers the ownership of a given token ID to another address\n If the target address is a contract, it must implement `onMockERC721Received`,\n which is called upon a safe transfer, and return the magic value\n `bytes4(keccak256(\"onMockERC721Received(address,address,uint256,bytes)\"))`; otherwise,\n the transfer is reverted.\n Requires the msg sender to be the owner, approved, or operator\n @param from current owner of the token\n @param to address to receive the ownership of the given token ID\n @param tokenId uint256 ID of the token to be transferred\n @param _data bytes data to send along with a safe transfer check"
},
"functionSelector": "b88d4fde",
"id": 2530,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "safeTransferFrom",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 2512,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2505,
"mutability": "mutable",
"name": "from",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2530,
"src": "14574:12:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 2504,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "14574:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 2507,
"mutability": "mutable",
"name": "to",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2530,
"src": "14588:10:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 2506,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "14588:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 2509,
"mutability": "mutable",
"name": "tokenId",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2530,
"src": "14600:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2508,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "14600:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 2511,
"mutability": "mutable",
"name": "_data",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2530,
"src": "14617:18:13",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes"
},
"typeName": {
"id": 2510,
"name": "bytes",
"nodeType": "ElementaryTypeName",
"src": "14617:5:13",
"typeDescriptions": {
"typeIdentifier": "t_bytes_storage_ptr",
"typeString": "bytes"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "14573:63:13"
},
"returnParameters": {
"id": 2513,
"nodeType": "ParameterList",
"parameters": [],
"src": "14645:0:13"
},
"scope": 2838,
"src": "14548:226:13",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
{
"body": {
"id": 2551,
"nodeType": "Block",
"src": "15026:89:13",
"statements": [
{
"assignments": [
2539
],
"declarations": [
{
"constant": false,
"id": 2539,
"mutability": "mutable",
"name": "owner",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2551,
"src": "15036:13:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 2538,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "15036:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 2543,
"initialValue": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 2540,
"name": "_tokenOwner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2255,
"src": "15052:11:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_uint256_$_t_address_$",
"typeString": "mapping(uint256 => address)"
}
},
"id": 2542,
"indexExpression": {
"argumentTypes": null,
"id": 2541,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2533,
"src": "15064:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "15052:20:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "15036:36:13"
},
{
"expression": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"id": 2549,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 2544,
"name": "owner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2539,
"src": "15089:5:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "BinaryOperation",
"operator": "!=",
"rightExpression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"hexValue": "30",
"id": 2547,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "15106:1:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
}
],
"id": 2546,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "ElementaryTypeNameExpression",
"src": "15098:7:13",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_address_$",
"typeString": "type(address)"
},
"typeName": {
"id": 2545,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "15098:7:13",
"typeDescriptions": {
"typeIdentifier": null,
"typeString": null
}
}
},
"id": 2548,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "15098:10:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
}
},
"src": "15089:19:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"functionReturnParameters": 2537,
"id": 2550,
"nodeType": "Return",
"src": "15082:26:13"
}
]
},
"documentation": {
"id": 2531,
"nodeType": "StructuredDocumentation",
"src": "14780:178:13",
"text": " @dev Returns whether the specified token exists\n @param tokenId uint256 ID of the token to query the existence of\n @return whether the token exists"
},
"id": 2552,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "_exists",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 2534,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2533,
"mutability": "mutable",
"name": "tokenId",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2552,
"src": "14980:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2532,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "14980:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "14979:17:13"
},
"returnParameters": {
"id": 2537,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2536,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2552,
"src": "15020:4:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 2535,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "15020:4:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "15019:6:13"
},
"scope": 2838,
"src": "14963:152:13",
"stateMutability": "view",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 2584,
"nodeType": "Block",
"src": "15569:155:13",
"statements": [
{
"assignments": [
2563
],
"declarations": [
{
"constant": false,
"id": 2563,
"mutability": "mutable",
"name": "owner",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2584,
"src": "15579:13:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 2562,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "15579:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 2567,
"initialValue": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 2565,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2557,
"src": "15603:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"id": 2564,
"name": "ownerOf",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2345,
"src": "15595:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$_t_uint256_$returns$_t_address_$",
"typeString": "function (uint256) view returns (address)"
}
},
"id": 2566,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "15595:16:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "15579:32:13"
},
{
"expression": {
"argumentTypes": null,
"components": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"id": 2581,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"id": 2576,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"id": 2570,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 2568,
"name": "spender",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2555,
"src": "15629:7:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "BinaryOperation",
"operator": "==",
"rightExpression": {
"argumentTypes": null,
"id": 2569,
"name": "owner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2563,
"src": "15640:5:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"src": "15629:16:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"nodeType": "BinaryOperation",
"operator": "||",
"rightExpression": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"id": 2575,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 2572,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2557,
"src": "15661:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"id": 2571,
"name": "getApproved",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2410,
"src": "15649:11:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$_t_uint256_$returns$_t_address_$",
"typeString": "function (uint256) view returns (address)"
}
},
"id": 2573,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "15649:20:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "BinaryOperation",
"operator": "==",
"rightExpression": {
"argumentTypes": null,
"id": 2574,
"name": "spender",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2555,
"src": "15673:7:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"src": "15649:31:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"src": "15629:51:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"nodeType": "BinaryOperation",
"operator": "||",
"rightExpression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 2578,
"name": "owner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2563,
"src": "15701:5:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 2579,
"name": "spender",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2555,
"src": "15708:7:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 2577,
"name": "isApprovedForAll",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2459,
"src": "15684:16:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$_t_address_$_t_address_$returns$_t_bool_$",
"typeString": "function (address,address) view returns (bool)"
}
},
"id": 2580,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "15684:32:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"src": "15629:87:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"id": 2582,
"isConstant": false,
"isInlineArray": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"nodeType": "TupleExpression",
"src": "15628:89:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"functionReturnParameters": 2561,
"id": 2583,
"nodeType": "Return",
"src": "15621:96:13"
}
]
},
"documentation": {
"id": 2553,
"nodeType": "StructuredDocumentation",
"src": "15121:352:13",
"text": " @dev Returns whether the given spender can transfer a given token ID\n @param spender address of the spender to query\n @param tokenId uint256 ID of the token to be transferred\n @return bool whether the msg.sender is approved for the given token ID,\n is an operator of the owner, or is the owner of the token"
},
"id": 2585,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "_isApprovedOrOwner",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 2558,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2555,
"mutability": "mutable",
"name": "spender",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2585,
"src": "15506:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 2554,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "15506:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 2557,
"mutability": "mutable",
"name": "tokenId",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2585,
"src": "15523:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2556,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "15523:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "15505:34:13"
},
"returnParameters": {
"id": 2561,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2560,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2585,
"src": "15563:4:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 2559,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "15563:4:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "15562:6:13"
},
"scope": 2838,
"src": "15478:246:13",
"stateMutability": "view",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 2635,
"nodeType": "Block",
"src": "16031:225:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"id": 2599,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 2594,
"name": "to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2588,
"src": "16049:2:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "BinaryOperation",
"operator": "!=",
"rightExpression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"hexValue": "30",
"id": 2597,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "16063:1:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
}
],
"id": 2596,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "ElementaryTypeNameExpression",
"src": "16055:7:13",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_address_$",
"typeString": "type(address)"
},
"typeName": {
"id": 2595,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "16055:7:13",
"typeDescriptions": {
"typeIdentifier": null,
"typeString": null
}
}
},
"id": 2598,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "16055:10:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
}
},
"src": "16049:16:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 2593,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "16041:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 2600,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "16041:25:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2601,
"nodeType": "ExpressionStatement",
"src": "16041:25:13"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 2606,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"nodeType": "UnaryOperation",
"operator": "!",
"prefix": true,
"src": "16084:17:13",
"subExpression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 2604,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2590,
"src": "16093:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"id": 2603,
"name": "_exists",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2552,
"src": "16085:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$_t_uint256_$returns$_t_bool_$",
"typeString": "function (uint256) view returns (bool)"
}
},
"id": 2605,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "16085:16:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 2602,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "16076:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 2607,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "16076:26:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2608,
"nodeType": "ExpressionStatement",
"src": "16076:26:13"
},
{
"expression": {
"argumentTypes": null,
"id": 2613,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 2609,
"name": "_tokenOwner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2255,
"src": "16113:11:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_uint256_$_t_address_$",
"typeString": "mapping(uint256 => address)"
}
},
"id": 2611,
"indexExpression": {
"argumentTypes": null,
"id": 2610,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2590,
"src": "16125:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": true,
"nodeType": "IndexAccess",
"src": "16113:20:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"id": 2612,
"name": "to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2588,
"src": "16136:2:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"src": "16113:25:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"id": 2614,
"nodeType": "ExpressionStatement",
"src": "16113:25:13"
},
{
"expression": {
"argumentTypes": null,
"id": 2624,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 2615,
"name": "_ownedTokensCount",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2263,
"src": "16148:17:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
"typeString": "mapping(address => uint256)"
}
},
"id": 2617,
"indexExpression": {
"argumentTypes": null,
"id": 2616,
"name": "to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2588,
"src": "16166:2:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": true,
"nodeType": "IndexAccess",
"src": "16148:21:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"hexValue": "31",
"id": 2622,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "16198:1:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_1_by_1",
"typeString": "int_const 1"
},
"value": "1"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_rational_1_by_1",
"typeString": "int_const 1"
}
],
"expression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 2618,
"name": "_ownedTokensCount",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2263,
"src": "16172:17:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
"typeString": "mapping(address => uint256)"
}
},
"id": 2620,
"indexExpression": {
"argumentTypes": null,
"id": 2619,
"name": "to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2588,
"src": "16190:2:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "16172:21:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 2621,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "add",
"nodeType": "MemberAccess",
"referencedDeclaration": 2132,
"src": "16172:25:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
"typeString": "function (uint256,uint256) pure returns (uint256)"
}
},
"id": 2623,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "16172:28:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "16148:52:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 2625,
"nodeType": "ExpressionStatement",
"src": "16148:52:13"
},
{
"eventCall": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"hexValue": "30",
"id": 2629,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "16233:1:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
}
],
"id": 2628,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "ElementaryTypeNameExpression",
"src": "16225:7:13",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_address_$",
"typeString": "type(address)"
},
"typeName": {
"id": 2627,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "16225:7:13",
"typeDescriptions": {
"typeIdentifier": null,
"typeString": null
}
}
},
"id": 2630,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "16225:10:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
}
},
{
"argumentTypes": null,
"id": 2631,
"name": "to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2588,
"src": "16237:2:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 2632,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2590,
"src": "16241:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
},
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"id": 2626,
"name": "Transfer",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1989,
"src": "16216:8:13",
"typeDescriptions": {
"typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$",
"typeString": "function (address,address,uint256)"
}
},
"id": 2633,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "16216:33:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2634,
"nodeType": "EmitStatement",
"src": "16211:38:13"
}
]
},
"documentation": {
"id": 2586,
"nodeType": "StructuredDocumentation",
"src": "15730:232:13",
"text": " @dev Internal function to mint a new token\n Reverts if the given token ID already exists\n @param to The address that will own the minted token\n @param tokenId uint256 ID of the token to be minted"
},
"id": 2636,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "_mintMockERC721",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 2591,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2588,
"mutability": "mutable",
"name": "to",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2636,
"src": "15992:10:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 2587,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "15992:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 2590,
"mutability": "mutable",
"name": "tokenId",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2636,
"src": "16004:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2589,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "16004:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "15991:29:13"
},
"returnParameters": {
"id": 2592,
"nodeType": "ParameterList",
"parameters": [],
"src": "16031:0:13"
},
"scope": 2838,
"src": "15967:289:13",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 2685,
"nodeType": "Block",
"src": "16595:249:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"id": 2649,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 2646,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2641,
"src": "16621:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"id": 2645,
"name": "ownerOf",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2345,
"src": "16613:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$_t_uint256_$returns$_t_address_$",
"typeString": "function (uint256) view returns (address)"
}
},
"id": 2647,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "16613:16:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "BinaryOperation",
"operator": "==",
"rightExpression": {
"argumentTypes": null,
"id": 2648,
"name": "owner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2639,
"src": "16633:5:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"src": "16613:25:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 2644,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "16605:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 2650,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "16605:34:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2651,
"nodeType": "ExpressionStatement",
"src": "16605:34:13"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 2653,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2641,
"src": "16665:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"id": 2652,
"name": "_clearApproval",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2833,
"src": "16650:14:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_uint256_$returns$__$",
"typeString": "function (uint256)"
}
},
"id": 2654,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "16650:23:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2655,
"nodeType": "ExpressionStatement",
"src": "16650:23:13"
},
{
"expression": {
"argumentTypes": null,
"id": 2665,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 2656,
"name": "_ownedTokensCount",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2263,
"src": "16684:17:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
"typeString": "mapping(address => uint256)"
}
},
"id": 2658,
"indexExpression": {
"argumentTypes": null,
"id": 2657,
"name": "owner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2639,
"src": "16702:5:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": true,
"nodeType": "IndexAccess",
"src": "16684:24:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"hexValue": "31",
"id": 2663,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "16740:1:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_1_by_1",
"typeString": "int_const 1"
},
"value": "1"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_rational_1_by_1",
"typeString": "int_const 1"
}
],
"expression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 2659,
"name": "_ownedTokensCount",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2263,
"src": "16711:17:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
"typeString": "mapping(address => uint256)"
}
},
"id": 2661,
"indexExpression": {
"argumentTypes": null,
"id": 2660,
"name": "owner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2639,
"src": "16729:5:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "16711:24:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 2662,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "sub",
"nodeType": "MemberAccess",
"referencedDeclaration": 2107,
"src": "16711:28:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
"typeString": "function (uint256,uint256) pure returns (uint256)"
}
},
"id": 2664,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "16711:31:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "16684:58:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 2666,
"nodeType": "ExpressionStatement",
"src": "16684:58:13"
},
{
"expression": {
"argumentTypes": null,
"id": 2674,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 2667,
"name": "_tokenOwner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2255,
"src": "16752:11:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_uint256_$_t_address_$",
"typeString": "mapping(uint256 => address)"
}
},
"id": 2669,
"indexExpression": {
"argumentTypes": null,
"id": 2668,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2641,
"src": "16764:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": true,
"nodeType": "IndexAccess",
"src": "16752:20:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"hexValue": "30",
"id": 2672,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "16783:1:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
}
],
"id": 2671,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "ElementaryTypeNameExpression",
"src": "16775:7:13",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_address_$",
"typeString": "type(address)"
},
"typeName": {
"id": 2670,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "16775:7:13",
"typeDescriptions": {
"typeIdentifier": null,
"typeString": null
}
}
},
"id": 2673,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "16775:10:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
}
},
"src": "16752:33:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"id": 2675,
"nodeType": "ExpressionStatement",
"src": "16752:33:13"
},
{
"eventCall": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 2677,
"name": "owner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2639,
"src": "16810:5:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"hexValue": "30",
"id": 2680,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "16825:1:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
}
],
"id": 2679,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "ElementaryTypeNameExpression",
"src": "16817:7:13",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_address_$",
"typeString": "type(address)"
},
"typeName": {
"id": 2678,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "16817:7:13",
"typeDescriptions": {
"typeIdentifier": null,
"typeString": null
}
}
},
"id": 2681,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "16817:10:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
}
},
{
"argumentTypes": null,
"id": 2682,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2641,
"src": "16829:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
},
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"id": 2676,
"name": "Transfer",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1989,
"src": "16801:8:13",
"typeDescriptions": {
"typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$",
"typeString": "function (address,address,uint256)"
}
},
"id": 2683,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "16801:36:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2684,
"nodeType": "EmitStatement",
"src": "16796:41:13"
}
]
},
"documentation": {
"id": 2637,
"nodeType": "StructuredDocumentation",
"src": "16262:262:13",
"text": " @dev Internal function to burn a specific token\n Reverts if the token does not exist\n Deprecated, use _burn(uint256) instead.\n @param owner owner of the token to burn\n @param tokenId uint256 ID of the token being burned"
},
"id": 2686,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "_burnMockERC721",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 2642,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2639,
"mutability": "mutable",
"name": "owner",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2686,
"src": "16554:13:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 2638,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "16554:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 2641,
"mutability": "mutable",
"name": "tokenId",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2686,
"src": "16569:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2640,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "16569:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "16553:32:13"
},
"returnParameters": {
"id": 2643,
"nodeType": "ParameterList",
"parameters": [],
"src": "16595:0:13"
},
"scope": 2838,
"src": "16529:315:13",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 2699,
"nodeType": "Block",
"src": "17064:59:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 2694,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2689,
"src": "17098:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"id": 2693,
"name": "ownerOf",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2345,
"src": "17090:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$_t_uint256_$returns$_t_address_$",
"typeString": "function (uint256) view returns (address)"
}
},
"id": 2695,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "17090:16:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 2696,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2689,
"src": "17108:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"id": 2692,
"name": "_burnMockERC721",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2686,
"src": "17074:15:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_uint256_$returns$__$",
"typeString": "function (address,uint256)"
}
},
"id": 2697,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "17074:42:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2698,
"nodeType": "ExpressionStatement",
"src": "17074:42:13"
}
]
},
"documentation": {
"id": 2687,
"nodeType": "StructuredDocumentation",
"src": "16850:168:13",
"text": " @dev Internal function to burn a specific token\n Reverts if the token does not exist\n @param tokenId uint256 ID of the token being burned"
},
"id": 2700,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "_burn",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 2690,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2689,
"mutability": "mutable",
"name": "tokenId",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2700,
"src": "17038:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2688,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "17038:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "17037:17:13"
},
"returnParameters": {
"id": 2691,
"nodeType": "ParameterList",
"parameters": [],
"src": "17064:0:13"
},
"scope": 2838,
"src": "17023:100:13",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 2765,
"nodeType": "Block",
"src": "17583:327:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"id": 2715,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 2712,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2707,
"src": "17609:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"id": 2711,
"name": "ownerOf",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2345,
"src": "17601:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$_t_uint256_$returns$_t_address_$",
"typeString": "function (uint256) view returns (address)"
}
},
"id": 2713,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "17601:16:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "BinaryOperation",
"operator": "==",
"rightExpression": {
"argumentTypes": null,
"id": 2714,
"name": "from",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2703,
"src": "17621:4:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"src": "17601:24:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 2710,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "17593:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 2716,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "17593:33:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2717,
"nodeType": "ExpressionStatement",
"src": "17593:33:13"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"id": 2724,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 2719,
"name": "to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2705,
"src": "17644:2:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "BinaryOperation",
"operator": "!=",
"rightExpression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"hexValue": "30",
"id": 2722,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "17658:1:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
}
],
"id": 2721,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "ElementaryTypeNameExpression",
"src": "17650:7:13",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_address_$",
"typeString": "type(address)"
},
"typeName": {
"id": 2720,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "17650:7:13",
"typeDescriptions": {
"typeIdentifier": null,
"typeString": null
}
}
},
"id": 2723,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "17650:10:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
}
},
"src": "17644:16:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 2718,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "17636:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 2725,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "17636:25:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2726,
"nodeType": "ExpressionStatement",
"src": "17636:25:13"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 2728,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2707,
"src": "17687:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"id": 2727,
"name": "_clearApproval",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2833,
"src": "17672:14:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_uint256_$returns$__$",
"typeString": "function (uint256)"
}
},
"id": 2729,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "17672:23:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2730,
"nodeType": "ExpressionStatement",
"src": "17672:23:13"
},
{
"expression": {
"argumentTypes": null,
"id": 2740,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 2731,
"name": "_ownedTokensCount",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2263,
"src": "17706:17:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
"typeString": "mapping(address => uint256)"
}
},
"id": 2733,
"indexExpression": {
"argumentTypes": null,
"id": 2732,
"name": "from",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2703,
"src": "17724:4:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": true,
"nodeType": "IndexAccess",
"src": "17706:23:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"hexValue": "31",
"id": 2738,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "17760:1:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_1_by_1",
"typeString": "int_const 1"
},
"value": "1"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_rational_1_by_1",
"typeString": "int_const 1"
}
],
"expression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 2734,
"name": "_ownedTokensCount",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2263,
"src": "17732:17:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
"typeString": "mapping(address => uint256)"
}
},
"id": 2736,
"indexExpression": {
"argumentTypes": null,
"id": 2735,
"name": "from",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2703,
"src": "17750:4:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "17732:23:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 2737,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "sub",
"nodeType": "MemberAccess",
"referencedDeclaration": 2107,
"src": "17732:27:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
"typeString": "function (uint256,uint256) pure returns (uint256)"
}
},
"id": 2739,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "17732:30:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "17706:56:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 2741,
"nodeType": "ExpressionStatement",
"src": "17706:56:13"
},
{
"expression": {
"argumentTypes": null,
"id": 2751,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 2742,
"name": "_ownedTokensCount",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2263,
"src": "17772:17:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
"typeString": "mapping(address => uint256)"
}
},
"id": 2744,
"indexExpression": {
"argumentTypes": null,
"id": 2743,
"name": "to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2705,
"src": "17790:2:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": true,
"nodeType": "IndexAccess",
"src": "17772:21:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"hexValue": "31",
"id": 2749,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "17822:1:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_1_by_1",
"typeString": "int_const 1"
},
"value": "1"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_rational_1_by_1",
"typeString": "int_const 1"
}
],
"expression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 2745,
"name": "_ownedTokensCount",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2263,
"src": "17796:17:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
"typeString": "mapping(address => uint256)"
}
},
"id": 2747,
"indexExpression": {
"argumentTypes": null,
"id": 2746,
"name": "to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2705,
"src": "17814:2:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "17796:21:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 2748,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "add",
"nodeType": "MemberAccess",
"referencedDeclaration": 2132,
"src": "17796:25:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
"typeString": "function (uint256,uint256) pure returns (uint256)"
}
},
"id": 2750,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "17796:28:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "17772:52:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 2752,
"nodeType": "ExpressionStatement",
"src": "17772:52:13"
},
{
"expression": {
"argumentTypes": null,
"id": 2757,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 2753,
"name": "_tokenOwner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2255,
"src": "17835:11:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_uint256_$_t_address_$",
"typeString": "mapping(uint256 => address)"
}
},
"id": 2755,
"indexExpression": {
"argumentTypes": null,
"id": 2754,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2707,
"src": "17847:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": true,
"nodeType": "IndexAccess",
"src": "17835:20:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"id": 2756,
"name": "to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2705,
"src": "17858:2:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"src": "17835:25:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"id": 2758,
"nodeType": "ExpressionStatement",
"src": "17835:25:13"
},
{
"eventCall": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 2760,
"name": "from",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2703,
"src": "17885:4:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 2761,
"name": "to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2705,
"src": "17891:2:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 2762,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2707,
"src": "17895:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"id": 2759,
"name": "Transfer",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1989,
"src": "17876:8:13",
"typeDescriptions": {
"typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$",
"typeString": "function (address,address,uint256)"
}
},
"id": 2763,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "17876:27:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2764,
"nodeType": "EmitStatement",
"src": "17871:32:13"
}
]
},
"documentation": {
"id": 2701,
"nodeType": "StructuredDocumentation",
"src": "17129:363:13",
"text": " @dev Internal function to transfer ownership of a given token ID to another address.\n As opposed to transferFrom, this imposes no restrictions on msg.sender.\n @param from current owner of the token\n @param to address to receive the ownership of the given token ID\n @param tokenId uint256 ID of the token to be transferred"
},
"id": 2766,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "_transferFromMockERC721",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 2708,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2703,
"mutability": "mutable",
"name": "from",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2766,
"src": "17530:12:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 2702,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "17530:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 2705,
"mutability": "mutable",
"name": "to",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2766,
"src": "17544:10:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 2704,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "17544:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 2707,
"mutability": "mutable",
"name": "tokenId",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2766,
"src": "17556:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2706,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "17556:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "17529:43:13"
},
"returnParameters": {
"id": 2709,
"nodeType": "ParameterList",
"parameters": [],
"src": "17583:0:13"
},
"scope": 2838,
"src": "17497:413:13",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 2806,
"nodeType": "Block",
"src": "18572:228:13",
"statements": [
{
"condition": {
"argumentTypes": null,
"id": 2783,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"nodeType": "UnaryOperation",
"operator": "!",
"prefix": true,
"src": "18586:16:13",
"subExpression": {
"argumentTypes": null,
"arguments": [],
"expression": {
"argumentTypes": [],
"expression": {
"argumentTypes": null,
"id": 2780,
"name": "to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2771,
"src": "18587:2:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"id": 2781,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "isContract",
"nodeType": "MemberAccess",
"referencedDeclaration": 2172,
"src": "18587:13:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$_t_address_$returns$_t_bool_$bound_to$_t_address_$",
"typeString": "function (address) view returns (bool)"
}
},
"id": 2782,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "18587:15:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"falseBody": null,
"id": 2787,
"nodeType": "IfStatement",
"src": "18582:58:13",
"trueBody": {
"id": 2786,
"nodeType": "Block",
"src": "18604:36:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"hexValue": "74727565",
"id": 2784,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "bool",
"lValueRequested": false,
"nodeType": "Literal",
"src": "18625:4:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"value": "true"
},
"functionReturnParameters": 2779,
"id": 2785,
"nodeType": "Return",
"src": "18618:11:13"
}
]
}
},
{
"assignments": [
2789
],
"declarations": [
{
"constant": false,
"id": 2789,
"mutability": "mutable",
"name": "retval",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2806,
"src": "18650:13:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
},
"typeName": {
"id": 2788,
"name": "bytes4",
"nodeType": "ElementaryTypeName",
"src": "18650:6:13",
"typeDescriptions": {
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 2800,
"initialValue": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 2794,
"name": "msg",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": -15,
"src": "18711:3:13",
"typeDescriptions": {
"typeIdentifier": "t_magic_message",
"typeString": "msg"
}
},
"id": 2795,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "sender",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "18711:10:13",
"typeDescriptions": {
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
}
},
{
"argumentTypes": null,
"id": 2796,
"name": "from",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2769,
"src": "18723:4:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 2797,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2773,
"src": "18729:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
{
"argumentTypes": null,
"id": 2798,
"name": "_data",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2775,
"src": "18738:5:13",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
},
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
{
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
],
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 2791,
"name": "to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2771,
"src": "18686:2:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 2790,
"name": "IMockERC721Receiver",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2022,
"src": "18666:19:13",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_contract$_IMockERC721Receiver_$2022_$",
"typeString": "type(contract IMockERC721Receiver)"
}
},
"id": 2792,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "18666:23:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_contract$_IMockERC721Receiver_$2022",
"typeString": "contract IMockERC721Receiver"
}
},
"id": 2793,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "onMockERC721Received",
"nodeType": "MemberAccess",
"referencedDeclaration": 2021,
"src": "18666:44:13",
"typeDescriptions": {
"typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$_t_uint256_$_t_bytes_memory_ptr_$returns$_t_bytes4_$",
"typeString": "function (address,address,uint256,bytes memory) external returns (bytes4)"
}
},
"id": 2799,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "18666:78:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "18650:94:13"
},
{
"expression": {
"argumentTypes": null,
"components": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
},
"id": 2803,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 2801,
"name": "retval",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2789,
"src": "18762:6:13",
"typeDescriptions": {
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
}
},
"nodeType": "BinaryOperation",
"operator": "==",
"rightExpression": {
"argumentTypes": null,
"id": 2802,
"name": "_MockERC721_RECEIVED",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2251,
"src": "18772:20:13",
"typeDescriptions": {
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
}
},
"src": "18762:30:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"id": 2804,
"isConstant": false,
"isInlineArray": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"nodeType": "TupleExpression",
"src": "18761:32:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"functionReturnParameters": 2779,
"id": 2805,
"nodeType": "Return",
"src": "18754:39:13"
}
]
},
"documentation": {
"id": 2767,
"nodeType": "StructuredDocumentation",
"src": "17916:516:13",
"text": " @dev Internal function to invoke `onMockERC721Received` on a target address\n The call is not executed if the target address is not a contract\n @param from address representing the previous owner of the given token ID\n @param to target address that will receive the tokens\n @param tokenId uint256 ID of the token to be transferred\n @param _data bytes optional data to send along with the call\n @return whether the call correctly returned the expected magic value"
},
"id": 2807,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "_checkOnMockERC721Received",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 2776,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2769,
"mutability": "mutable",
"name": "from",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2807,
"src": "18473:12:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 2768,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "18473:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 2771,
"mutability": "mutable",
"name": "to",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2807,
"src": "18487:10:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 2770,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "18487:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 2773,
"mutability": "mutable",
"name": "tokenId",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2807,
"src": "18499:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2772,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "18499:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 2775,
"mutability": "mutable",
"name": "_data",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2807,
"src": "18516:18:13",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes"
},
"typeName": {
"id": 2774,
"name": "bytes",
"nodeType": "ElementaryTypeName",
"src": "18516:5:13",
"typeDescriptions": {
"typeIdentifier": "t_bytes_storage_ptr",
"typeString": "bytes"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "18472:63:13"
},
"returnParameters": {
"id": 2779,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2778,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2807,
"src": "18562:4:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 2777,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "18562:4:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "18561:6:13"
},
"scope": 2838,
"src": "18437:363:13",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 2832,
"nodeType": "Block",
"src": "19010:122:13",
"statements": [
{
"condition": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"id": 2820,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 2813,
"name": "_tokenApprovals",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2259,
"src": "19024:15:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_uint256_$_t_address_$",
"typeString": "mapping(uint256 => address)"
}
},
"id": 2815,
"indexExpression": {
"argumentTypes": null,
"id": 2814,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2810,
"src": "19040:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "19024:24:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "BinaryOperation",
"operator": "!=",
"rightExpression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"hexValue": "30",
"id": 2818,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "19060:1:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
}
],
"id": 2817,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "ElementaryTypeNameExpression",
"src": "19052:7:13",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_address_$",
"typeString": "type(address)"
},
"typeName": {
"id": 2816,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "19052:7:13",
"typeDescriptions": {
"typeIdentifier": null,
"typeString": null
}
}
},
"id": 2819,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "19052:10:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
}
},
"src": "19024:38:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"falseBody": null,
"id": 2831,
"nodeType": "IfStatement",
"src": "19020:106:13",
"trueBody": {
"id": 2830,
"nodeType": "Block",
"src": "19064:62:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"id": 2828,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 2821,
"name": "_tokenApprovals",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2259,
"src": "19078:15:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_uint256_$_t_address_$",
"typeString": "mapping(uint256 => address)"
}
},
"id": 2823,
"indexExpression": {
"argumentTypes": null,
"id": 2822,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2810,
"src": "19094:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": true,
"nodeType": "IndexAccess",
"src": "19078:24:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"hexValue": "30",
"id": 2826,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "19113:1:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
}
],
"id": 2825,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "ElementaryTypeNameExpression",
"src": "19105:7:13",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_address_$",
"typeString": "type(address)"
},
"typeName": {
"id": 2824,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "19105:7:13",
"typeDescriptions": {
"typeIdentifier": null,
"typeString": null
}
}
},
"id": 2827,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "19105:10:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
}
},
"src": "19078:37:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"id": 2829,
"nodeType": "ExpressionStatement",
"src": "19078:37:13"
}
]
}
}
]
},
"documentation": {
"id": 2808,
"nodeType": "StructuredDocumentation",
"src": "18806:150:13",
"text": " @dev Private function to clear current approval of a given token ID\n @param tokenId uint256 ID of the token to be transferred"
},
"id": 2833,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "_clearApproval",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 2811,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2810,
"mutability": "mutable",
"name": "tokenId",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2833,
"src": "18985:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2809,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "18985:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "18984:17:13"
},
"returnParameters": {
"id": 2812,
"nodeType": "ParameterList",
"parameters": [],
"src": "19010:0:13"
},
"scope": 2838,
"src": "18961:171:13",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "private"
},
{
"constant": false,
"id": 2837,
"mutability": "mutable",
"name": "______gap",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2838,
"src": "19138:29:13",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$50_storage",
"typeString": "uint256[50]"
},
"typeName": {
"baseType": {
"id": 2834,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "19138:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 2836,
"length": {
"argumentTypes": null,
"hexValue": "3530",
"id": 2835,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "19146:2:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_50_by_1",
"typeString": "int_const 50"
},
"value": "50"
},
"nodeType": "ArrayTypeName",
"src": "19138:11:13",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$50_storage_ptr",
"typeString": "uint256[50]"
}
},
"value": null,
"visibility": "private"
}
],
"scope": 4171,
"src": "7638:11532:13"
},
{
"abstract": true,
"baseContracts": [
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 2840,
"name": "Initializable",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 74,
"src": "19439:13:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_Initializable_$74",
"typeString": "contract Initializable"
}
},
"id": 2841,
"nodeType": "InheritanceSpecifier",
"src": "19439:13:13"
},
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 2842,
"name": "IMockERC721",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 2006,
"src": "19454:11:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IMockERC721_$2006",
"typeString": "contract IMockERC721"
}
},
"id": 2843,
"nodeType": "InheritanceSpecifier",
"src": "19454:11:13"
}
],
"contractDependencies": [
74,
1976,
2006
],
"contractKind": "contract",
"documentation": {
"id": 2839,
"nodeType": "StructuredDocumentation",
"src": "19237:158:13",
"text": " @title ERC-721 Non-Fungible Token Standard, optional enumeration extension\n @dev See https://github.com/ethereum/EIPs/blob/master/EIPS/eip-721.md"
},
"fullyImplemented": false,
"id": 2865,
"linearizedBaseContracts": [
2865,
2006,
1976,
74
],
"name": "IMockERC721Enumerable",
"nodeType": "ContractDefinition",
"nodes": [
{
"body": null,
"documentation": null,
"functionSelector": "18160ddd",
"id": 2848,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "totalSupply",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 2844,
"nodeType": "ParameterList",
"parameters": [],
"src": "19492:2:13"
},
"returnParameters": {
"id": 2847,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2846,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2848,
"src": "19524:7:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2845,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "19524:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "19523:9:13"
},
"scope": 2865,
"src": "19472:61:13",
"stateMutability": "view",
"virtual": true,
"visibility": "public"
},
{
"body": null,
"documentation": null,
"functionSelector": "2f745c59",
"id": 2857,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "tokenOfOwnerByIndex",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 2853,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2850,
"mutability": "mutable",
"name": "owner",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2857,
"src": "19567:13:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 2849,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "19567:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 2852,
"mutability": "mutable",
"name": "index",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2857,
"src": "19582:13:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2851,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "19582:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "19566:30:13"
},
"returnParameters": {
"id": 2856,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2855,
"mutability": "mutable",
"name": "tokenId",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2857,
"src": "19626:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2854,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "19626:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "19625:17:13"
},
"scope": 2865,
"src": "19538:105:13",
"stateMutability": "view",
"virtual": true,
"visibility": "public"
},
{
"body": null,
"documentation": null,
"functionSelector": "4f6ccce7",
"id": 2864,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "tokenByIndex",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 2860,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2859,
"mutability": "mutable",
"name": "index",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2864,
"src": "19671:13:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2858,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "19671:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "19670:15:13"
},
"returnParameters": {
"id": 2863,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2862,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2864,
"src": "19715:7:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2861,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "19715:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "19714:9:13"
},
"scope": 2865,
"src": "19649:75:13",
"stateMutability": "view",
"virtual": true,
"visibility": "public"
}
],
"scope": 4171,
"src": "19396:330:13"
},
{
"abstract": false,
"baseContracts": [
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 2867,
"name": "Initializable",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 74,
"src": "19987:13:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_Initializable_$74",
"typeString": "contract Initializable"
}
},
"id": 2868,
"nodeType": "InheritanceSpecifier",
"src": "19987:13:13"
},
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 2869,
"name": "ERC165",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 2235,
"src": "20002:6:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_ERC165_$2235",
"typeString": "contract ERC165"
}
},
"id": 2870,
"nodeType": "InheritanceSpecifier",
"src": "20002:6:13"
},
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 2871,
"name": "MockERC721",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 2838,
"src": "20010:10:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_MockERC721_$2838",
"typeString": "contract MockERC721"
}
},
"id": 2872,
"nodeType": "InheritanceSpecifier",
"src": "20010:10:13"
},
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 2873,
"name": "IMockERC721Enumerable",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 2865,
"src": "20022:21:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IMockERC721Enumerable_$2865",
"typeString": "contract IMockERC721Enumerable"
}
},
"id": 2874,
"nodeType": "InheritanceSpecifier",
"src": "20022:21:13"
}
],
"contractDependencies": [
74,
1976,
2006,
2235,
2838,
2865
],
"contractKind": "contract",
"documentation": {
"id": 2866,
"nodeType": "StructuredDocumentation",
"src": "19794:159:13",
"text": " @title ERC-721 Non-Fungible Token with optional enumeration extension logic\n @dev See https://github.com/ethereum/EIPs/blob/master/EIPS/eip-721.md"
},
"fullyImplemented": true,
"id": 3229,
"linearizedBaseContracts": [
3229,
2865,
2838,
2006,
2235,
1976,
74
],
"name": "MockERC721Enumerable",
"nodeType": "ContractDefinition",
"nodes": [
{
"constant": false,
"id": 2879,
"mutability": "mutable",
"name": "_ownedTokens",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3229,
"src": "20103:50:13",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_array$_t_uint256_$dyn_storage_$",
"typeString": "mapping(address => uint256[])"
},
"typeName": {
"id": 2878,
"keyType": {
"id": 2875,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "20111:7:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "Mapping",
"src": "20103:29:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_array$_t_uint256_$dyn_storage_$",
"typeString": "mapping(address => uint256[])"
},
"valueType": {
"baseType": {
"id": 2876,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "20122:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 2877,
"length": null,
"nodeType": "ArrayTypeName",
"src": "20122:9:13",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$dyn_storage_ptr",
"typeString": "uint256[]"
}
}
},
"value": null,
"visibility": "private"
},
{
"constant": false,
"id": 2883,
"mutability": "mutable",
"name": "_ownedTokensIndex",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3229,
"src": "20223:53:13",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_uint256_$_t_uint256_$",
"typeString": "mapping(uint256 => uint256)"
},
"typeName": {
"id": 2882,
"keyType": {
"id": 2880,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "20231:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "Mapping",
"src": "20223:27:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_uint256_$_t_uint256_$",
"typeString": "mapping(uint256 => uint256)"
},
"valueType": {
"id": 2881,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "20242:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
},
"value": null,
"visibility": "private"
},
{
"constant": false,
"id": 2886,
"mutability": "mutable",
"name": "_allTokens",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3229,
"src": "20337:28:13",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$dyn_storage",
"typeString": "uint256[]"
},
"typeName": {
"baseType": {
"id": 2884,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "20337:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 2885,
"length": null,
"nodeType": "ArrayTypeName",
"src": "20337:9:13",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$dyn_storage_ptr",
"typeString": "uint256[]"
}
},
"value": null,
"visibility": "private"
},
{
"constant": false,
"id": 2890,
"mutability": "mutable",
"name": "_allTokensIndex",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3229,
"src": "20436:51:13",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_uint256_$_t_uint256_$",
"typeString": "mapping(uint256 => uint256)"
},
"typeName": {
"id": 2889,
"keyType": {
"id": 2887,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "20444:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "Mapping",
"src": "20436:27:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_uint256_$_t_uint256_$",
"typeString": "mapping(uint256 => uint256)"
},
"valueType": {
"id": 2888,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "20455:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
},
"value": null,
"visibility": "private"
},
{
"constant": true,
"id": 2893,
"mutability": "constant",
"name": "_INTERFACE_ID_MockERC721_ENUMERABLE",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3229,
"src": "20494:72:13",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
},
"typeName": {
"id": 2891,
"name": "bytes4",
"nodeType": "ElementaryTypeName",
"src": "20494:6:13",
"typeDescriptions": {
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
}
},
"value": {
"argumentTypes": null,
"hexValue": "30783738306539643633",
"id": 2892,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "20556:10:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_2014223715_by_1",
"typeString": "int_const 2014223715"
},
"value": "0x780e9d63"
},
"visibility": "private"
},
{
"body": {
"id": 2909,
"nodeType": "Block",
"src": "20894:214:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [],
"expression": {
"argumentTypes": [],
"expression": {
"argumentTypes": null,
"id": 2900,
"name": "MockERC721",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2838,
"src": "20912:10:13",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_contract$_MockERC721_$2838_$",
"typeString": "type(contract MockERC721)"
}
},
"id": 2901,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "_hasBeenInitializedMockERC721",
"nodeType": "MemberAccess",
"referencedDeclaration": 2297,
"src": "20912:40:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$__$returns$_t_bool_$",
"typeString": "function () view returns (bool)"
}
},
"id": 2902,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "20912:42:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 2899,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "20904:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 2903,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "20904:51:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2904,
"nodeType": "ExpressionStatement",
"src": "20904:51:13"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 2906,
"name": "_INTERFACE_ID_MockERC721_ENUMERABLE",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2893,
"src": "21065:35:13",
"typeDescriptions": {
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
}
],
"id": 2905,
"name": "_registerInterface",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2230,
"src": "21046:18:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_bytes4_$returns$__$",
"typeString": "function (bytes4)"
}
},
"id": 2907,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "21046:55:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2908,
"nodeType": "ExpressionStatement",
"src": "21046:55:13"
}
]
},
"documentation": {
"id": 2894,
"nodeType": "StructuredDocumentation",
"src": "20784:44:13",
"text": " @dev Constructor function"
},
"functionSelector": "ba774307",
"id": 2910,
"implemented": true,
"kind": "function",
"modifiers": [
{
"arguments": null,
"id": 2897,
"modifierName": {
"argumentTypes": null,
"id": 2896,
"name": "initializer",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 47,
"src": "20882:11:13",
"typeDescriptions": {
"typeIdentifier": "t_modifier$__$",
"typeString": "modifier ()"
}
},
"nodeType": "ModifierInvocation",
"src": "20882:11:13"
}
],
"name": "initializeMockERC721Enumerable",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 2895,
"nodeType": "ParameterList",
"parameters": [],
"src": "20872:2:13"
},
"returnParameters": {
"id": 2898,
"nodeType": "ParameterList",
"parameters": [],
"src": "20894:0:13"
},
"scope": 3229,
"src": "20833:275:13",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
{
"body": {
"id": 2919,
"nodeType": "Block",
"src": "21182:78:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 2916,
"name": "_INTERFACE_ID_MockERC721_ENUMERABLE",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2893,
"src": "21217:35:13",
"typeDescriptions": {
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
}
],
"id": 2915,
"name": "supportsInterface",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2211,
"src": "21199:17:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$_t_bytes4_$returns$_t_bool_$",
"typeString": "function (bytes4) view returns (bool)"
}
},
"id": 2917,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "21199:54:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"functionReturnParameters": 2914,
"id": 2918,
"nodeType": "Return",
"src": "21192:61:13"
}
]
},
"documentation": null,
"id": 2920,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "_hasBeenInitialized",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 2911,
"nodeType": "ParameterList",
"parameters": [],
"src": "21142:2:13"
},
"returnParameters": {
"id": 2914,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2913,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2920,
"src": "21176:4:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 2912,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "21176:4:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "21175:6:13"
},
"scope": 3229,
"src": "21114:146:13",
"stateMutability": "view",
"virtual": true,
"visibility": "internal"
},
{
"baseFunctions": [
2857
],
"body": {
"id": 2945,
"nodeType": "Block",
"src": "21731:93:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 2936,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 2932,
"name": "index",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2925,
"src": "21749:5:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "<",
"rightExpression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 2934,
"name": "owner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2923,
"src": "21767:5:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 2933,
"name": "balanceOf",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2319,
"src": "21757:9:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$_t_address_$returns$_t_uint256_$",
"typeString": "function (address) view returns (uint256)"
}
},
"id": 2935,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "21757:16:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "21749:24:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 2931,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "21741:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 2937,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "21741:33:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2938,
"nodeType": "ExpressionStatement",
"src": "21741:33:13"
},
{
"expression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 2939,
"name": "_ownedTokens",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2879,
"src": "21791:12:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_array$_t_uint256_$dyn_storage_$",
"typeString": "mapping(address => uint256[] storage ref)"
}
},
"id": 2941,
"indexExpression": {
"argumentTypes": null,
"id": 2940,
"name": "owner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2923,
"src": "21804:5:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "21791:19:13",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$dyn_storage",
"typeString": "uint256[] storage ref"
}
},
"id": 2943,
"indexExpression": {
"argumentTypes": null,
"id": 2942,
"name": "index",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2925,
"src": "21811:5:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "21791:26:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"functionReturnParameters": 2930,
"id": 2944,
"nodeType": "Return",
"src": "21784:33:13"
}
]
},
"documentation": {
"id": 2921,
"nodeType": "StructuredDocumentation",
"src": "21266:362:13",
"text": " @dev Gets the token ID at a given index of the tokens list of the requested owner\n @param owner address owning the tokens list to be accessed\n @param index uint256 representing the index to be accessed of the requested tokens list\n @return uint256 token ID at the given index of the tokens list owned by the requested address"
},
"functionSelector": "2f745c59",
"id": 2946,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "tokenOfOwnerByIndex",
"nodeType": "FunctionDefinition",
"overrides": {
"id": 2927,
"nodeType": "OverrideSpecifier",
"overrides": [],
"src": "21704:8:13"
},
"parameters": {
"id": 2926,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2923,
"mutability": "mutable",
"name": "owner",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2946,
"src": "21662:13:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 2922,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "21662:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 2925,
"mutability": "mutable",
"name": "index",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2946,
"src": "21677:13:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2924,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "21677:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "21661:30:13"
},
"returnParameters": {
"id": 2930,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2929,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2946,
"src": "21722:7:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2928,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "21722:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "21721:9:13"
},
"scope": 3229,
"src": "21633:191:13",
"stateMutability": "view",
"virtual": false,
"visibility": "public"
},
{
"baseFunctions": [
2848
],
"body": {
"id": 2956,
"nodeType": "Block",
"src": "22038:41:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 2953,
"name": "_allTokens",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2886,
"src": "22055:10:13",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$dyn_storage",
"typeString": "uint256[] storage ref"
}
},
"id": 2954,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "length",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "22055:17:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"functionReturnParameters": 2952,
"id": 2955,
"nodeType": "Return",
"src": "22048:24:13"
}
]
},
"documentation": {
"id": 2947,
"nodeType": "StructuredDocumentation",
"src": "21830:141:13",
"text": " @dev Gets the total amount of tokens stored by the contract\n @return uint256 representing the total amount of tokens"
},
"functionSelector": "18160ddd",
"id": 2957,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "totalSupply",
"nodeType": "FunctionDefinition",
"overrides": {
"id": 2949,
"nodeType": "OverrideSpecifier",
"overrides": [],
"src": "22011:8:13"
},
"parameters": {
"id": 2948,
"nodeType": "ParameterList",
"parameters": [],
"src": "21996:2:13"
},
"returnParameters": {
"id": 2952,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2951,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2957,
"src": "22029:7:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2950,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "22029:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "22028:9:13"
},
"scope": 3229,
"src": "21976:103:13",
"stateMutability": "view",
"virtual": false,
"visibility": "public"
},
{
"baseFunctions": [
2864
],
"body": {
"id": 2977,
"nodeType": "Block",
"src": "22492:81:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 2970,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 2967,
"name": "index",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2960,
"src": "22510:5:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "<",
"rightExpression": {
"argumentTypes": null,
"arguments": [],
"expression": {
"argumentTypes": [],
"id": 2968,
"name": "totalSupply",
"nodeType": "Identifier",
"overloadedDeclarations": [
2957
],
"referencedDeclaration": 2957,
"src": "22518:11:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$__$returns$_t_uint256_$",
"typeString": "function () view returns (uint256)"
}
},
"id": 2969,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "22518:13:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "22510:21:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 2966,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "22502:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 2971,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "22502:30:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2972,
"nodeType": "ExpressionStatement",
"src": "22502:30:13"
},
{
"expression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 2973,
"name": "_allTokens",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2886,
"src": "22549:10:13",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$dyn_storage",
"typeString": "uint256[] storage ref"
}
},
"id": 2975,
"indexExpression": {
"argumentTypes": null,
"id": 2974,
"name": "index",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2960,
"src": "22560:5:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "22549:17:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"functionReturnParameters": 2965,
"id": 2976,
"nodeType": "Return",
"src": "22542:24:13"
}
]
},
"documentation": {
"id": 2958,
"nodeType": "StructuredDocumentation",
"src": "22085:326:13",
"text": " @dev Gets the token ID at a given index of all the tokens in this contract\n Reverts if the index is greater or equal to the total number of tokens\n @param index uint256 representing the index to be accessed of the tokens list\n @return uint256 token ID at the given index of the tokens list"
},
"functionSelector": "4f6ccce7",
"id": 2978,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "tokenByIndex",
"nodeType": "FunctionDefinition",
"overrides": {
"id": 2962,
"nodeType": "OverrideSpecifier",
"overrides": [],
"src": "22465:8:13"
},
"parameters": {
"id": 2961,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2960,
"mutability": "mutable",
"name": "index",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2978,
"src": "22438:13:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2959,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "22438:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "22437:15:13"
},
"returnParameters": {
"id": 2965,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2964,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 2978,
"src": "22483:7:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2963,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "22483:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "22482:9:13"
},
"scope": 3229,
"src": "22416:157:13",
"stateMutability": "view",
"virtual": false,
"visibility": "public"
},
{
"body": {
"id": 3006,
"nodeType": "Block",
"src": "23023:174:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 2991,
"name": "from",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2981,
"src": "23063:4:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 2992,
"name": "to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2983,
"src": "23069:2:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 2993,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2985,
"src": "23073:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"expression": {
"argumentTypes": null,
"id": 2988,
"name": "super",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": -25,
"src": "23033:5:13",
"typeDescriptions": {
"typeIdentifier": "t_super$_MockERC721Enumerable_$3229",
"typeString": "contract super MockERC721Enumerable"
}
},
"id": 2990,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "_transferFromMockERC721",
"nodeType": "MemberAccess",
"referencedDeclaration": 2766,
"src": "23033:29:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$",
"typeString": "function (address,address,uint256)"
}
},
"id": 2994,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "23033:48:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 2995,
"nodeType": "ExpressionStatement",
"src": "23033:48:13"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 2997,
"name": "from",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2981,
"src": "23125:4:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 2998,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2985,
"src": "23131:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"id": 2996,
"name": "_removeTokenFromOwnerEnumeration",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3180,
"src": "23092:32:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_uint256_$returns$__$",
"typeString": "function (address,uint256)"
}
},
"id": 2999,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "23092:47:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3000,
"nodeType": "ExpressionStatement",
"src": "23092:47:13"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3002,
"name": "to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2983,
"src": "23178:2:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 3003,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2985,
"src": "23182:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"id": 3001,
"name": "_addTokenToOwnerEnumeration",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3102,
"src": "23150:27:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_uint256_$returns$__$",
"typeString": "function (address,uint256)"
}
},
"id": 3004,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "23150:40:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3005,
"nodeType": "ExpressionStatement",
"src": "23150:40:13"
}
]
},
"documentation": {
"id": 2979,
"nodeType": "StructuredDocumentation",
"src": "22579:363:13",
"text": " @dev Internal function to transfer ownership of a given token ID to another address.\n As opposed to transferFrom, this imposes no restrictions on msg.sender.\n @param from current owner of the token\n @param to address to receive the ownership of the given token ID\n @param tokenId uint256 ID of the token to be transferred"
},
"id": 3007,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "_transferFrom",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 2986,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 2981,
"mutability": "mutable",
"name": "from",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3007,
"src": "22970:12:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 2980,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "22970:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 2983,
"mutability": "mutable",
"name": "to",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3007,
"src": "22984:10:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 2982,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "22984:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 2985,
"mutability": "mutable",
"name": "tokenId",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3007,
"src": "22996:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 2984,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "22996:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "22969:43:13"
},
"returnParameters": {
"id": 2987,
"nodeType": "ParameterList",
"parameters": [],
"src": "23023:0:13"
},
"scope": 3229,
"src": "22947:250:13",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 3031,
"nodeType": "Block",
"src": "23513:153:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3018,
"name": "to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3010,
"src": "23545:2:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 3019,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3012,
"src": "23549:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"expression": {
"argumentTypes": null,
"id": 3015,
"name": "super",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": -25,
"src": "23523:5:13",
"typeDescriptions": {
"typeIdentifier": "t_super$_MockERC721Enumerable_$3229",
"typeString": "contract super MockERC721Enumerable"
}
},
"id": 3017,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "_mintMockERC721",
"nodeType": "MemberAccess",
"referencedDeclaration": 2636,
"src": "23523:21:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_uint256_$returns$__$",
"typeString": "function (address,uint256)"
}
},
"id": 3020,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "23523:34:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3021,
"nodeType": "ExpressionStatement",
"src": "23523:34:13"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3023,
"name": "to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3010,
"src": "23596:2:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 3024,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3012,
"src": "23600:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"id": 3022,
"name": "_addTokenToOwnerEnumeration",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3102,
"src": "23568:27:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_uint256_$returns$__$",
"typeString": "function (address,uint256)"
}
},
"id": 3025,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "23568:40:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3026,
"nodeType": "ExpressionStatement",
"src": "23568:40:13"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3028,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3012,
"src": "23651:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"id": 3027,
"name": "_addTokenToAllTokensEnumeration",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3122,
"src": "23619:31:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_uint256_$returns$__$",
"typeString": "function (uint256)"
}
},
"id": 3029,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "23619:40:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3030,
"nodeType": "ExpressionStatement",
"src": "23619:40:13"
}
]
},
"documentation": {
"id": 3008,
"nodeType": "StructuredDocumentation",
"src": "23203:244:13",
"text": " @dev Internal function to mint a new token\n Reverts if the given token ID already exists\n @param to address the beneficiary that will own the minted token\n @param tokenId uint256 ID of the token to be minted"
},
"id": 3032,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "_mint",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 3013,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3010,
"mutability": "mutable",
"name": "to",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3032,
"src": "23467:10:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3009,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "23467:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 3012,
"mutability": "mutable",
"name": "tokenId",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3032,
"src": "23479:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 3011,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "23479:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "23466:29:13"
},
"returnParameters": {
"id": 3014,
"nodeType": "ParameterList",
"parameters": [],
"src": "23513:0:13"
},
"scope": 3229,
"src": "23452:214:13",
"stateMutability": "nonpayable",
"virtual": true,
"visibility": "internal"
},
{
"body": {
"id": 3062,
"nodeType": "Block",
"src": "24002:318:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3043,
"name": "owner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3035,
"src": "24034:5:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 3044,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3037,
"src": "24041:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"expression": {
"argumentTypes": null,
"id": 3040,
"name": "super",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": -25,
"src": "24012:5:13",
"typeDescriptions": {
"typeIdentifier": "t_super$_MockERC721Enumerable_$3229",
"typeString": "contract super MockERC721Enumerable"
}
},
"id": 3042,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "_burnMockERC721",
"nodeType": "MemberAccess",
"referencedDeclaration": 2686,
"src": "24012:21:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_uint256_$returns$__$",
"typeString": "function (address,uint256)"
}
},
"id": 3045,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "24012:37:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3046,
"nodeType": "ExpressionStatement",
"src": "24012:37:13"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3048,
"name": "owner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3035,
"src": "24093:5:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 3049,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3037,
"src": "24100:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"id": 3047,
"name": "_removeTokenFromOwnerEnumeration",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3180,
"src": "24060:32:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_uint256_$returns$__$",
"typeString": "function (address,uint256)"
}
},
"id": 3050,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "24060:48:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3051,
"nodeType": "ExpressionStatement",
"src": "24060:48:13"
},
{
"expression": {
"argumentTypes": null,
"id": 3056,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 3052,
"name": "_ownedTokensIndex",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2883,
"src": "24227:17:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_uint256_$_t_uint256_$",
"typeString": "mapping(uint256 => uint256)"
}
},
"id": 3054,
"indexExpression": {
"argumentTypes": null,
"id": 3053,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3037,
"src": "24245:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": true,
"nodeType": "IndexAccess",
"src": "24227:26:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"hexValue": "30",
"id": 3055,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "24256:1:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
},
"src": "24227:30:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3057,
"nodeType": "ExpressionStatement",
"src": "24227:30:13"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3059,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3037,
"src": "24305:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"id": 3058,
"name": "_removeTokenFromAllTokensEnumeration",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3224,
"src": "24268:36:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_uint256_$returns$__$",
"typeString": "function (uint256)"
}
},
"id": 3060,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "24268:45:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3061,
"nodeType": "ExpressionStatement",
"src": "24268:45:13"
}
]
},
"documentation": {
"id": 3033,
"nodeType": "StructuredDocumentation",
"src": "23672:261:13",
"text": " @dev Internal function to burn a specific token\n Reverts if the token does not exist\n Deprecated, use _burn(uint256) instead\n @param owner owner of the token to burn\n @param tokenId uint256 ID of the token being burned"
},
"id": 3063,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "_burn",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 3038,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3035,
"mutability": "mutable",
"name": "owner",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3063,
"src": "23953:13:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3034,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "23953:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 3037,
"mutability": "mutable",
"name": "tokenId",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3063,
"src": "23968:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 3036,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "23968:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "23952:32:13"
},
"returnParameters": {
"id": 3039,
"nodeType": "ParameterList",
"parameters": [],
"src": "24002:0:13"
},
"scope": 3229,
"src": "23938:382:13",
"stateMutability": "nonpayable",
"virtual": true,
"visibility": "internal"
},
{
"body": {
"id": 3076,
"nodeType": "Block",
"src": "24605:43:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 3072,
"name": "_ownedTokens",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2879,
"src": "24622:12:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_array$_t_uint256_$dyn_storage_$",
"typeString": "mapping(address => uint256[] storage ref)"
}
},
"id": 3074,
"indexExpression": {
"argumentTypes": null,
"id": 3073,
"name": "owner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3066,
"src": "24635:5:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "24622:19:13",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$dyn_storage",
"typeString": "uint256[] storage ref"
}
},
"functionReturnParameters": 3071,
"id": 3075,
"nodeType": "Return",
"src": "24615:26:13"
}
]
},
"documentation": {
"id": 3064,
"nodeType": "StructuredDocumentation",
"src": "24326:193:13",
"text": " @dev Gets the list of token IDs of the requested owner\n @param owner address owning the tokens\n @return uint256[] List of token IDs owned by the requested address"
},
"id": 3077,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "_tokensOfOwner",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 3067,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3066,
"mutability": "mutable",
"name": "owner",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3077,
"src": "24548:13:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3065,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "24548:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "24547:15:13"
},
"returnParameters": {
"id": 3071,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3070,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3077,
"src": "24586:17:13",
"stateVariable": false,
"storageLocation": "storage",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$dyn_storage_ptr",
"typeString": "uint256[]"
},
"typeName": {
"baseType": {
"id": 3068,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "24586:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3069,
"length": null,
"nodeType": "ArrayTypeName",
"src": "24586:9:13",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$dyn_storage_ptr",
"typeString": "uint256[]"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "24585:19:13"
},
"scope": 3229,
"src": "24524:124:13",
"stateMutability": "view",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 3101,
"nodeType": "Block",
"src": "25016:109:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"id": 3092,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 3085,
"name": "_ownedTokensIndex",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2883,
"src": "25026:17:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_uint256_$_t_uint256_$",
"typeString": "mapping(uint256 => uint256)"
}
},
"id": 3087,
"indexExpression": {
"argumentTypes": null,
"id": 3086,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3082,
"src": "25044:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": true,
"nodeType": "IndexAccess",
"src": "25026:26:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 3088,
"name": "_ownedTokens",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2879,
"src": "25055:12:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_array$_t_uint256_$dyn_storage_$",
"typeString": "mapping(address => uint256[] storage ref)"
}
},
"id": 3090,
"indexExpression": {
"argumentTypes": null,
"id": 3089,
"name": "to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3080,
"src": "25068:2:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "25055:16:13",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$dyn_storage",
"typeString": "uint256[] storage ref"
}
},
"id": 3091,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "length",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "25055:23:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "25026:52:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3093,
"nodeType": "ExpressionStatement",
"src": "25026:52:13"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3098,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3082,
"src": "25110:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"expression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 3094,
"name": "_ownedTokens",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2879,
"src": "25088:12:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_array$_t_uint256_$dyn_storage_$",
"typeString": "mapping(address => uint256[] storage ref)"
}
},
"id": 3096,
"indexExpression": {
"argumentTypes": null,
"id": 3095,
"name": "to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3080,
"src": "25101:2:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "25088:16:13",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$dyn_storage",
"typeString": "uint256[] storage ref"
}
},
"id": 3097,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "push",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "25088:21:13",
"typeDescriptions": {
"typeIdentifier": "t_function_arraypush_nonpayable$_t_uint256_$returns$__$",
"typeString": "function (uint256)"
}
},
"id": 3099,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "25088:30:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3100,
"nodeType": "ExpressionStatement",
"src": "25088:30:13"
}
]
},
"documentation": {
"id": 3078,
"nodeType": "StructuredDocumentation",
"src": "24654:283:13",
"text": " @dev Private function to add a token to this extension's ownership-tracking data structures.\n @param to address representing the new owner of the given token ID\n @param tokenId uint256 ID of the token to be added to the tokens list of the given address"
},
"id": 3102,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "_addTokenToOwnerEnumeration",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 3083,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3080,
"mutability": "mutable",
"name": "to",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3102,
"src": "24979:10:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3079,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "24979:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 3082,
"mutability": "mutable",
"name": "tokenId",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3102,
"src": "24991:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 3081,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "24991:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "24978:29:13"
},
"returnParameters": {
"id": 3084,
"nodeType": "ParameterList",
"parameters": [],
"src": "25016:0:13"
},
"scope": 3229,
"src": "24942:183:13",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "private"
},
{
"body": {
"id": 3121,
"nodeType": "Block",
"src": "25386:95:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"id": 3113,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 3108,
"name": "_allTokensIndex",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2890,
"src": "25396:15:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_uint256_$_t_uint256_$",
"typeString": "mapping(uint256 => uint256)"
}
},
"id": 3110,
"indexExpression": {
"argumentTypes": null,
"id": 3109,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3105,
"src": "25412:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": true,
"nodeType": "IndexAccess",
"src": "25396:24:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 3111,
"name": "_allTokens",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2886,
"src": "25423:10:13",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$dyn_storage",
"typeString": "uint256[] storage ref"
}
},
"id": 3112,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "length",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "25423:17:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "25396:44:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3114,
"nodeType": "ExpressionStatement",
"src": "25396:44:13"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3118,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3105,
"src": "25466:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"expression": {
"argumentTypes": null,
"id": 3115,
"name": "_allTokens",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2886,
"src": "25450:10:13",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$dyn_storage",
"typeString": "uint256[] storage ref"
}
},
"id": 3117,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "push",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "25450:15:13",
"typeDescriptions": {
"typeIdentifier": "t_function_arraypush_nonpayable$_t_uint256_$returns$__$",
"typeString": "function (uint256)"
}
},
"id": 3119,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "25450:24:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3120,
"nodeType": "ExpressionStatement",
"src": "25450:24:13"
}
]
},
"documentation": {
"id": 3103,
"nodeType": "StructuredDocumentation",
"src": "25131:184:13",
"text": " @dev Private function to add a token to this extension's token tracking data structures.\n @param tokenId uint256 ID of the token to be added to the tokens list"
},
"id": 3122,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "_addTokenToAllTokensEnumeration",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 3106,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3105,
"mutability": "mutable",
"name": "tokenId",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3122,
"src": "25361:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 3104,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "25361:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "25360:17:13"
},
"returnParameters": {
"id": 3107,
"nodeType": "ParameterList",
"parameters": [],
"src": "25386:0:13"
},
"scope": 3229,
"src": "25320:161:13",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "private"
},
{
"body": {
"id": 3179,
"nodeType": "Block",
"src": "26177:1082:13",
"statements": [
{
"assignments": [
3131
],
"declarations": [
{
"constant": false,
"id": 3131,
"mutability": "mutable",
"name": "lastTokenIndex",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3179,
"src": "26358:22:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 3130,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "26358:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 3139,
"initialValue": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"hexValue": "31",
"id": 3137,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "26413:1:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_1_by_1",
"typeString": "int_const 1"
},
"value": "1"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_rational_1_by_1",
"typeString": "int_const 1"
}
],
"expression": {
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 3132,
"name": "_ownedTokens",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2879,
"src": "26383:12:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_array$_t_uint256_$dyn_storage_$",
"typeString": "mapping(address => uint256[] storage ref)"
}
},
"id": 3134,
"indexExpression": {
"argumentTypes": null,
"id": 3133,
"name": "from",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3125,
"src": "26396:4:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "26383:18:13",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$dyn_storage",
"typeString": "uint256[] storage ref"
}
},
"id": 3135,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "length",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "26383:25:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3136,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "sub",
"nodeType": "MemberAccess",
"referencedDeclaration": 2107,
"src": "26383:29:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
"typeString": "function (uint256,uint256) pure returns (uint256)"
}
},
"id": 3138,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "26383:32:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "26358:57:13"
},
{
"assignments": [
3141
],
"declarations": [
{
"constant": false,
"id": 3141,
"mutability": "mutable",
"name": "tokenIndex",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3179,
"src": "26425:18:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 3140,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "26425:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 3145,
"initialValue": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 3142,
"name": "_ownedTokensIndex",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2883,
"src": "26446:17:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_uint256_$_t_uint256_$",
"typeString": "mapping(uint256 => uint256)"
}
},
"id": 3144,
"indexExpression": {
"argumentTypes": null,
"id": 3143,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3127,
"src": "26464:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "26446:26:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "26425:47:13"
},
{
"condition": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 3148,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 3146,
"name": "tokenIndex",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3141,
"src": "26576:10:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "!=",
"rightExpression": {
"argumentTypes": null,
"id": 3147,
"name": "lastTokenIndex",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3131,
"src": "26590:14:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "26576:28:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"falseBody": null,
"id": 3172,
"nodeType": "IfStatement",
"src": "26572:323:13",
"trueBody": {
"id": 3171,
"nodeType": "Block",
"src": "26606:289:13",
"statements": [
{
"assignments": [
3150
],
"declarations": [
{
"constant": false,
"id": 3150,
"mutability": "mutable",
"name": "lastTokenId",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3171,
"src": "26620:19:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 3149,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "26620:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 3156,
"initialValue": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 3151,
"name": "_ownedTokens",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2879,
"src": "26642:12:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_array$_t_uint256_$dyn_storage_$",
"typeString": "mapping(address => uint256[] storage ref)"
}
},
"id": 3153,
"indexExpression": {
"argumentTypes": null,
"id": 3152,
"name": "from",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3125,
"src": "26655:4:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "26642:18:13",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$dyn_storage",
"typeString": "uint256[] storage ref"
}
},
"id": 3155,
"indexExpression": {
"argumentTypes": null,
"id": 3154,
"name": "lastTokenIndex",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3131,
"src": "26661:14:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "26642:34:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "26620:56:13"
},
{
"expression": {
"argumentTypes": null,
"id": 3163,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 3157,
"name": "_ownedTokens",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2879,
"src": "26691:12:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_array$_t_uint256_$dyn_storage_$",
"typeString": "mapping(address => uint256[] storage ref)"
}
},
"id": 3160,
"indexExpression": {
"argumentTypes": null,
"id": 3158,
"name": "from",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3125,
"src": "26704:4:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "26691:18:13",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$dyn_storage",
"typeString": "uint256[] storage ref"
}
},
"id": 3161,
"indexExpression": {
"argumentTypes": null,
"id": 3159,
"name": "tokenIndex",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3141,
"src": "26710:10:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": true,
"nodeType": "IndexAccess",
"src": "26691:30:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"id": 3162,
"name": "lastTokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3150,
"src": "26724:11:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "26691:44:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3164,
"nodeType": "ExpressionStatement",
"src": "26691:44:13"
},
{
"expression": {
"argumentTypes": null,
"id": 3169,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 3165,
"name": "_ownedTokensIndex",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2883,
"src": "26807:17:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_uint256_$_t_uint256_$",
"typeString": "mapping(uint256 => uint256)"
}
},
"id": 3167,
"indexExpression": {
"argumentTypes": null,
"id": 3166,
"name": "lastTokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3150,
"src": "26825:11:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": true,
"nodeType": "IndexAccess",
"src": "26807:30:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"id": 3168,
"name": "tokenIndex",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3141,
"src": "26840:10:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "26807:43:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3170,
"nodeType": "ExpressionStatement",
"src": "26807:43:13"
}
]
}
},
{
"expression": {
"argumentTypes": null,
"arguments": [],
"expression": {
"argumentTypes": [],
"expression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 3173,
"name": "_ownedTokens",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2879,
"src": "27020:12:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_array$_t_uint256_$dyn_storage_$",
"typeString": "mapping(address => uint256[] storage ref)"
}
},
"id": 3175,
"indexExpression": {
"argumentTypes": null,
"id": 3174,
"name": "from",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3125,
"src": "27033:4:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "27020:18:13",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$dyn_storage",
"typeString": "uint256[] storage ref"
}
},
"id": 3176,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "pop",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "27020:22:13",
"typeDescriptions": {
"typeIdentifier": "t_function_arraypop_nonpayable$__$returns$__$",
"typeString": "function ()"
}
},
"id": 3177,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "27020:24:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3178,
"nodeType": "ExpressionStatement",
"src": "27020:24:13"
}
]
},
"documentation": {
"id": 3123,
"nodeType": "StructuredDocumentation",
"src": "25487:604:13",
"text": " @dev Private function to remove a token from this extension's ownership-tracking data structures. Note that\n while the token is not assigned a new owner, the _ownedTokensIndex mapping is _not_ updated: this allows for\n gas optimizations e.g. when performing a transfer operation (avoiding double writes).\n This has O(1) time complexity, but alters the order of the _ownedTokens array.\n @param from address representing the previous owner of the given token ID\n @param tokenId uint256 ID of the token to be removed from the tokens list of the given address"
},
"id": 3180,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "_removeTokenFromOwnerEnumeration",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 3128,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3125,
"mutability": "mutable",
"name": "from",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3180,
"src": "26138:12:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3124,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "26138:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 3127,
"mutability": "mutable",
"name": "tokenId",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3180,
"src": "26152:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 3126,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "26152:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "26137:31:13"
},
"returnParameters": {
"id": 3129,
"nodeType": "ParameterList",
"parameters": [],
"src": "26177:0:13"
},
"scope": 3229,
"src": "26096:1163:13",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "private"
},
{
"body": {
"id": 3223,
"nodeType": "Block",
"src": "27618:992:13",
"statements": [
{
"assignments": [
3187
],
"declarations": [
{
"constant": false,
"id": 3187,
"mutability": "mutable",
"name": "lastTokenIndex",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3223,
"src": "27796:22:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 3186,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "27796:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 3193,
"initialValue": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"hexValue": "31",
"id": 3191,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "27843:1:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_1_by_1",
"typeString": "int_const 1"
},
"value": "1"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_rational_1_by_1",
"typeString": "int_const 1"
}
],
"expression": {
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 3188,
"name": "_allTokens",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2886,
"src": "27821:10:13",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$dyn_storage",
"typeString": "uint256[] storage ref"
}
},
"id": 3189,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "length",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "27821:17:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3190,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "sub",
"nodeType": "MemberAccess",
"referencedDeclaration": 2107,
"src": "27821:21:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
"typeString": "function (uint256,uint256) pure returns (uint256)"
}
},
"id": 3192,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "27821:24:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "27796:49:13"
},
{
"assignments": [
3195
],
"declarations": [
{
"constant": false,
"id": 3195,
"mutability": "mutable",
"name": "tokenIndex",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3223,
"src": "27855:18:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 3194,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "27855:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 3199,
"initialValue": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 3196,
"name": "_allTokensIndex",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2890,
"src": "27876:15:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_uint256_$_t_uint256_$",
"typeString": "mapping(uint256 => uint256)"
}
},
"id": 3198,
"indexExpression": {
"argumentTypes": null,
"id": 3197,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3183,
"src": "27892:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "27876:24:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "27855:45:13"
},
{
"assignments": [
3201
],
"declarations": [
{
"constant": false,
"id": 3201,
"mutability": "mutable",
"name": "lastTokenId",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3223,
"src": "28222:19:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 3200,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "28222:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 3205,
"initialValue": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 3202,
"name": "_allTokens",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2886,
"src": "28244:10:13",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$dyn_storage",
"typeString": "uint256[] storage ref"
}
},
"id": 3204,
"indexExpression": {
"argumentTypes": null,
"id": 3203,
"name": "lastTokenIndex",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3187,
"src": "28255:14:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "28244:26:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "28222:48:13"
},
{
"expression": {
"argumentTypes": null,
"id": 3210,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 3206,
"name": "_allTokens",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2886,
"src": "28281:10:13",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$dyn_storage",
"typeString": "uint256[] storage ref"
}
},
"id": 3208,
"indexExpression": {
"argumentTypes": null,
"id": 3207,
"name": "tokenIndex",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3195,
"src": "28292:10:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": true,
"nodeType": "IndexAccess",
"src": "28281:22:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"id": 3209,
"name": "lastTokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3201,
"src": "28306:11:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "28281:36:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3211,
"nodeType": "ExpressionStatement",
"src": "28281:36:13"
},
{
"expression": {
"argumentTypes": null,
"id": 3216,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 3212,
"name": "_allTokensIndex",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2890,
"src": "28385:15:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_uint256_$_t_uint256_$",
"typeString": "mapping(uint256 => uint256)"
}
},
"id": 3214,
"indexExpression": {
"argumentTypes": null,
"id": 3213,
"name": "lastTokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3201,
"src": "28401:11:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": true,
"nodeType": "IndexAccess",
"src": "28385:28:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"id": 3215,
"name": "tokenIndex",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3195,
"src": "28416:10:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "28385:41:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3217,
"nodeType": "ExpressionStatement",
"src": "28385:41:13"
},
{
"expression": {
"argumentTypes": null,
"arguments": [],
"expression": {
"argumentTypes": [],
"expression": {
"argumentTypes": null,
"id": 3218,
"name": "_allTokens",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2886,
"src": "28547:10:13",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$dyn_storage",
"typeString": "uint256[] storage ref"
}
},
"id": 3220,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "pop",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "28547:14:13",
"typeDescriptions": {
"typeIdentifier": "t_function_arraypop_nonpayable$__$returns$__$",
"typeString": "function ()"
}
},
"id": 3221,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "28547:16:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3222,
"nodeType": "ExpressionStatement",
"src": "28547:16:13"
}
]
},
"documentation": {
"id": 3181,
"nodeType": "StructuredDocumentation",
"src": "27265:277:13",
"text": " @dev Private function to remove a token from this extension's token tracking data structures.\n This has O(1) time complexity, but alters the order of the _allTokens array.\n @param tokenId uint256 ID of the token to be removed from the tokens list"
},
"id": 3224,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "_removeTokenFromAllTokensEnumeration",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 3184,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3183,
"mutability": "mutable",
"name": "tokenId",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3224,
"src": "27593:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 3182,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "27593:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "27592:17:13"
},
"returnParameters": {
"id": 3185,
"nodeType": "ParameterList",
"parameters": [],
"src": "27618:0:13"
},
"scope": 3229,
"src": "27547:1063:13",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "private"
},
{
"constant": false,
"id": 3228,
"mutability": "mutable",
"name": "______gap",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3229,
"src": "28616:29:13",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$50_storage",
"typeString": "uint256[50]"
},
"typeName": {
"baseType": {
"id": 3225,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "28616:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3227,
"length": {
"argumentTypes": null,
"hexValue": "3530",
"id": 3226,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "28624:2:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_50_by_1",
"typeString": "int_const 50"
},
"value": "50"
},
"nodeType": "ArrayTypeName",
"src": "28616:11:13",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$50_storage_ptr",
"typeString": "uint256[50]"
}
},
"value": null,
"visibility": "private"
}
],
"scope": 4171,
"src": "19954:8694:13"
},
{
"abstract": true,
"baseContracts": [
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 3231,
"name": "Initializable",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 74,
"src": "28910:13:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_Initializable_$74",
"typeString": "contract Initializable"
}
},
"id": 3232,
"nodeType": "InheritanceSpecifier",
"src": "28910:13:13"
},
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 3233,
"name": "IMockERC721",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 2006,
"src": "28925:11:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IMockERC721_$2006",
"typeString": "contract IMockERC721"
}
},
"id": 3234,
"nodeType": "InheritanceSpecifier",
"src": "28925:11:13"
}
],
"contractDependencies": [
74,
1976,
2006
],
"contractKind": "contract",
"documentation": {
"id": 3230,
"nodeType": "StructuredDocumentation",
"src": "28713:155:13",
"text": " @title ERC-721 Non-Fungible Token Standard, optional metadata extension\n @dev See https://github.com/ethereum/EIPs/blob/master/EIPS/eip-721.md"
},
"fullyImplemented": false,
"id": 3252,
"linearizedBaseContracts": [
3252,
2006,
1976,
74
],
"name": "IMockERC721Metadata",
"nodeType": "ContractDefinition",
"nodes": [
{
"body": null,
"documentation": null,
"functionSelector": "06fdde03",
"id": 3239,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "name",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 3235,
"nodeType": "ParameterList",
"parameters": [],
"src": "28956:2:13"
},
"returnParameters": {
"id": 3238,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3237,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3239,
"src": "28990:13:13",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_string_memory_ptr",
"typeString": "string"
},
"typeName": {
"id": 3236,
"name": "string",
"nodeType": "ElementaryTypeName",
"src": "28990:6:13",
"typeDescriptions": {
"typeIdentifier": "t_string_storage_ptr",
"typeString": "string"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "28989:15:13"
},
"scope": 3252,
"src": "28943:62:13",
"stateMutability": "view",
"virtual": true,
"visibility": "external"
},
{
"body": null,
"documentation": null,
"functionSelector": "95d89b41",
"id": 3244,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "symbol",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 3240,
"nodeType": "ParameterList",
"parameters": [],
"src": "29025:2:13"
},
"returnParameters": {
"id": 3243,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3242,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3244,
"src": "29059:13:13",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_string_memory_ptr",
"typeString": "string"
},
"typeName": {
"id": 3241,
"name": "string",
"nodeType": "ElementaryTypeName",
"src": "29059:6:13",
"typeDescriptions": {
"typeIdentifier": "t_string_storage_ptr",
"typeString": "string"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "29058:15:13"
},
"scope": 3252,
"src": "29010:64:13",
"stateMutability": "view",
"virtual": true,
"visibility": "external"
},
{
"body": null,
"documentation": null,
"functionSelector": "c87b56dd",
"id": 3251,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "tokenURI",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 3247,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3246,
"mutability": "mutable",
"name": "tokenId",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3251,
"src": "29097:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 3245,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "29097:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "29096:17:13"
},
"returnParameters": {
"id": 3250,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3249,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3251,
"src": "29145:13:13",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_string_memory_ptr",
"typeString": "string"
},
"typeName": {
"id": 3248,
"name": "string",
"nodeType": "ElementaryTypeName",
"src": "29145:6:13",
"typeDescriptions": {
"typeIdentifier": "t_string_storage_ptr",
"typeString": "string"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "29144:15:13"
},
"scope": 3252,
"src": "29079:81:13",
"stateMutability": "view",
"virtual": true,
"visibility": "external"
}
],
"scope": 4171,
"src": "28869:293:13"
},
{
"abstract": false,
"baseContracts": [
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 3253,
"name": "Initializable",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 74,
"src": "29259:13:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_Initializable_$74",
"typeString": "contract Initializable"
}
},
"id": 3254,
"nodeType": "InheritanceSpecifier",
"src": "29259:13:13"
},
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 3255,
"name": "ERC165",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 2235,
"src": "29274:6:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_ERC165_$2235",
"typeString": "contract ERC165"
}
},
"id": 3256,
"nodeType": "InheritanceSpecifier",
"src": "29274:6:13"
},
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 3257,
"name": "MockERC721",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 2838,
"src": "29282:10:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_MockERC721_$2838",
"typeString": "contract MockERC721"
}
},
"id": 3258,
"nodeType": "InheritanceSpecifier",
"src": "29282:10:13"
},
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 3259,
"name": "IMockERC721Metadata",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 3252,
"src": "29294:19:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IMockERC721Metadata_$3252",
"typeString": "contract IMockERC721Metadata"
}
},
"id": 3260,
"nodeType": "InheritanceSpecifier",
"src": "29294:19:13"
}
],
"contractDependencies": [
74,
1976,
2006,
2235,
2838,
3252
],
"contractKind": "contract",
"documentation": null,
"fullyImplemented": true,
"id": 3408,
"linearizedBaseContracts": [
3408,
3252,
2838,
2006,
2235,
1976,
74
],
"name": "MockERC721Metadata",
"nodeType": "ContractDefinition",
"nodes": [
{
"constant": false,
"id": 3262,
"mutability": "mutable",
"name": "_name",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3408,
"src": "29338:20:13",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_string_storage",
"typeString": "string"
},
"typeName": {
"id": 3261,
"name": "string",
"nodeType": "ElementaryTypeName",
"src": "29338:6:13",
"typeDescriptions": {
"typeIdentifier": "t_string_storage_ptr",
"typeString": "string"
}
},
"value": null,
"visibility": "private"
},
{
"constant": false,
"id": 3264,
"mutability": "mutable",
"name": "_symbol",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3408,
"src": "29385:22:13",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_string_storage",
"typeString": "string"
},
"typeName": {
"id": 3263,
"name": "string",
"nodeType": "ElementaryTypeName",
"src": "29385:6:13",
"typeDescriptions": {
"typeIdentifier": "t_string_storage_ptr",
"typeString": "string"
}
},
"value": null,
"visibility": "private"
},
{
"constant": false,
"id": 3268,
"mutability": "mutable",
"name": "_tokenURIs",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3408,
"src": "29453:45:13",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_uint256_$_t_string_storage_$",
"typeString": "mapping(uint256 => string)"
},
"typeName": {
"id": 3267,
"keyType": {
"id": 3265,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "29461:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "Mapping",
"src": "29453:26:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_uint256_$_t_string_storage_$",
"typeString": "mapping(uint256 => string)"
},
"valueType": {
"id": 3266,
"name": "string",
"nodeType": "ElementaryTypeName",
"src": "29472:6:13",
"typeDescriptions": {
"typeIdentifier": "t_string_storage_ptr",
"typeString": "string"
}
}
},
"value": null,
"visibility": "private"
},
{
"constant": true,
"id": 3271,
"mutability": "constant",
"name": "_INTERFACE_ID_MockERC721_METADATA",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3408,
"src": "29505:70:13",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
},
"typeName": {
"id": 3269,
"name": "bytes4",
"nodeType": "ElementaryTypeName",
"src": "29505:6:13",
"typeDescriptions": {
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
}
},
"value": {
"argumentTypes": null,
"hexValue": "30783562356531333966",
"id": 3270,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "29565:10:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_1532892063_by_1",
"typeString": "int_const 1532892063"
},
"value": "0x5b5e139f"
},
"visibility": "private"
},
{
"body": {
"id": 3299,
"nodeType": "Block",
"src": "29884:262:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [],
"expression": {
"argumentTypes": [],
"expression": {
"argumentTypes": null,
"id": 3282,
"name": "MockERC721",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2838,
"src": "29902:10:13",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_contract$_MockERC721_$2838_$",
"typeString": "type(contract MockERC721)"
}
},
"id": 3283,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "_hasBeenInitializedMockERC721",
"nodeType": "MemberAccess",
"referencedDeclaration": 2297,
"src": "29902:40:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$__$returns$_t_bool_$",
"typeString": "function () view returns (bool)"
}
},
"id": 3284,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "29902:42:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 3281,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "29894:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 3285,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "29894:51:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3286,
"nodeType": "ExpressionStatement",
"src": "29894:51:13"
},
{
"expression": {
"argumentTypes": null,
"id": 3289,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"id": 3287,
"name": "_name",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3262,
"src": "29956:5:13",
"typeDescriptions": {
"typeIdentifier": "t_string_storage",
"typeString": "string storage ref"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"id": 3288,
"name": "name",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3274,
"src": "29964:4:13",
"typeDescriptions": {
"typeIdentifier": "t_string_memory_ptr",
"typeString": "string memory"
}
},
"src": "29956:12:13",
"typeDescriptions": {
"typeIdentifier": "t_string_storage",
"typeString": "string storage ref"
}
},
"id": 3290,
"nodeType": "ExpressionStatement",
"src": "29956:12:13"
},
{
"expression": {
"argumentTypes": null,
"id": 3293,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"id": 3291,
"name": "_symbol",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3264,
"src": "29978:7:13",
"typeDescriptions": {
"typeIdentifier": "t_string_storage",
"typeString": "string storage ref"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"id": 3292,
"name": "symbol",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3276,
"src": "29988:6:13",
"typeDescriptions": {
"typeIdentifier": "t_string_memory_ptr",
"typeString": "string memory"
}
},
"src": "29978:16:13",
"typeDescriptions": {
"typeIdentifier": "t_string_storage",
"typeString": "string storage ref"
}
},
"id": 3294,
"nodeType": "ExpressionStatement",
"src": "29978:16:13"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3296,
"name": "_INTERFACE_ID_MockERC721_METADATA",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3271,
"src": "30105:33:13",
"typeDescriptions": {
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
}
],
"id": 3295,
"name": "_registerInterface",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2230,
"src": "30086:18:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_bytes4_$returns$__$",
"typeString": "function (bytes4)"
}
},
"id": 3297,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "30086:53:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3298,
"nodeType": "ExpressionStatement",
"src": "30086:53:13"
}
]
},
"documentation": {
"id": 3272,
"nodeType": "StructuredDocumentation",
"src": "29754:44:13",
"text": " @dev Constructor function"
},
"functionSelector": "4cd88b76",
"id": 3300,
"implemented": true,
"kind": "function",
"modifiers": [
{
"arguments": null,
"id": 3279,
"modifierName": {
"argumentTypes": null,
"id": 3278,
"name": "initializer",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 47,
"src": "29872:11:13",
"typeDescriptions": {
"typeIdentifier": "t_modifier$__$",
"typeString": "modifier ()"
}
},
"nodeType": "ModifierInvocation",
"src": "29872:11:13"
}
],
"name": "initialize",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 3277,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3274,
"mutability": "mutable",
"name": "name",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3300,
"src": "29823:18:13",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_string_memory_ptr",
"typeString": "string"
},
"typeName": {
"id": 3273,
"name": "string",
"nodeType": "ElementaryTypeName",
"src": "29823:6:13",
"typeDescriptions": {
"typeIdentifier": "t_string_storage_ptr",
"typeString": "string"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 3276,
"mutability": "mutable",
"name": "symbol",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3300,
"src": "29843:20:13",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_string_memory_ptr",
"typeString": "string"
},
"typeName": {
"id": 3275,
"name": "string",
"nodeType": "ElementaryTypeName",
"src": "29843:6:13",
"typeDescriptions": {
"typeIdentifier": "t_string_storage_ptr",
"typeString": "string"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "29822:42:13"
},
"returnParameters": {
"id": 3280,
"nodeType": "ParameterList",
"parameters": [],
"src": "29884:0:13"
},
"scope": 3408,
"src": "29803:343:13",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
{
"body": {
"id": 3309,
"nodeType": "Block",
"src": "30220:76:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3306,
"name": "_INTERFACE_ID_MockERC721_METADATA",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3271,
"src": "30255:33:13",
"typeDescriptions": {
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
}
],
"id": 3305,
"name": "supportsInterface",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2211,
"src": "30237:17:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$_t_bytes4_$returns$_t_bool_$",
"typeString": "function (bytes4) view returns (bool)"
}
},
"id": 3307,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "30237:52:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"functionReturnParameters": 3304,
"id": 3308,
"nodeType": "Return",
"src": "30230:59:13"
}
]
},
"documentation": null,
"id": 3310,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "_hasBeenInitialized",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 3301,
"nodeType": "ParameterList",
"parameters": [],
"src": "30180:2:13"
},
"returnParameters": {
"id": 3304,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3303,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3310,
"src": "30214:4:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 3302,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "30214:4:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "30213:6:13"
},
"scope": 3408,
"src": "30152:144:13",
"stateMutability": "view",
"virtual": true,
"visibility": "internal"
},
{
"baseFunctions": [
3239
],
"body": {
"id": 3319,
"nodeType": "Block",
"src": "30463:29:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"id": 3317,
"name": "_name",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3262,
"src": "30480:5:13",
"typeDescriptions": {
"typeIdentifier": "t_string_storage",
"typeString": "string storage ref"
}
},
"functionReturnParameters": 3316,
"id": 3318,
"nodeType": "Return",
"src": "30473:12:13"
}
]
},
"documentation": {
"id": 3311,
"nodeType": "StructuredDocumentation",
"src": "30302:93:13",
"text": " @dev Gets the token name\n @return string representing the token name"
},
"functionSelector": "06fdde03",
"id": 3320,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "name",
"nodeType": "FunctionDefinition",
"overrides": {
"id": 3313,
"nodeType": "OverrideSpecifier",
"overrides": [],
"src": "30430:8:13"
},
"parameters": {
"id": 3312,
"nodeType": "ParameterList",
"parameters": [],
"src": "30413:2:13"
},
"returnParameters": {
"id": 3316,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3315,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3320,
"src": "30448:13:13",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_string_memory_ptr",
"typeString": "string"
},
"typeName": {
"id": 3314,
"name": "string",
"nodeType": "ElementaryTypeName",
"src": "30448:6:13",
"typeDescriptions": {
"typeIdentifier": "t_string_storage_ptr",
"typeString": "string"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "30447:15:13"
},
"scope": 3408,
"src": "30400:92:13",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"baseFunctions": [
3244
],
"body": {
"id": 3329,
"nodeType": "Block",
"src": "30665:31:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"id": 3327,
"name": "_symbol",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3264,
"src": "30682:7:13",
"typeDescriptions": {
"typeIdentifier": "t_string_storage",
"typeString": "string storage ref"
}
},
"functionReturnParameters": 3326,
"id": 3328,
"nodeType": "Return",
"src": "30675:14:13"
}
]
},
"documentation": {
"id": 3321,
"nodeType": "StructuredDocumentation",
"src": "30498:97:13",
"text": " @dev Gets the token symbol\n @return string representing the token symbol"
},
"functionSelector": "95d89b41",
"id": 3330,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "symbol",
"nodeType": "FunctionDefinition",
"overrides": {
"id": 3323,
"nodeType": "OverrideSpecifier",
"overrides": [],
"src": "30632:8:13"
},
"parameters": {
"id": 3322,
"nodeType": "ParameterList",
"parameters": [],
"src": "30615:2:13"
},
"returnParameters": {
"id": 3326,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3325,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3330,
"src": "30650:13:13",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_string_memory_ptr",
"typeString": "string"
},
"typeName": {
"id": 3324,
"name": "string",
"nodeType": "ElementaryTypeName",
"src": "30650:6:13",
"typeDescriptions": {
"typeIdentifier": "t_string_storage_ptr",
"typeString": "string"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "30649:15:13"
},
"scope": 3408,
"src": "30600:96:13",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"baseFunctions": [
3251
],
"body": {
"id": 3349,
"nodeType": "Block",
"src": "30977:78:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3341,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3333,
"src": "31003:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"id": 3340,
"name": "_exists",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2552,
"src": "30995:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$_t_uint256_$returns$_t_bool_$",
"typeString": "function (uint256) view returns (bool)"
}
},
"id": 3342,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "30995:16:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 3339,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "30987:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 3343,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "30987:25:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3344,
"nodeType": "ExpressionStatement",
"src": "30987:25:13"
},
{
"expression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 3345,
"name": "_tokenURIs",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3268,
"src": "31029:10:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_uint256_$_t_string_storage_$",
"typeString": "mapping(uint256 => string storage ref)"
}
},
"id": 3347,
"indexExpression": {
"argumentTypes": null,
"id": 3346,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3333,
"src": "31040:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "31029:19:13",
"typeDescriptions": {
"typeIdentifier": "t_string_storage",
"typeString": "string storage ref"
}
},
"functionReturnParameters": 3338,
"id": 3348,
"nodeType": "Return",
"src": "31022:26:13"
}
]
},
"documentation": {
"id": 3331,
"nodeType": "StructuredDocumentation",
"src": "30702:188:13",
"text": " @dev Returns an URI for a given token ID\n Throws if the token ID does not exist. May return an empty string.\n @param tokenId uint256 ID of the token to query"
},
"functionSelector": "c87b56dd",
"id": 3350,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "tokenURI",
"nodeType": "FunctionDefinition",
"overrides": {
"id": 3335,
"nodeType": "OverrideSpecifier",
"overrides": [],
"src": "30944:8:13"
},
"parameters": {
"id": 3334,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3333,
"mutability": "mutable",
"name": "tokenId",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3350,
"src": "30913:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 3332,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "30913:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "30912:17:13"
},
"returnParameters": {
"id": 3338,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3337,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3350,
"src": "30962:13:13",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_string_memory_ptr",
"typeString": "string"
},
"typeName": {
"id": 3336,
"name": "string",
"nodeType": "ElementaryTypeName",
"src": "30962:6:13",
"typeDescriptions": {
"typeIdentifier": "t_string_storage_ptr",
"typeString": "string"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "30961:15:13"
},
"scope": 3408,
"src": "30895:160:13",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"body": {
"id": 3370,
"nodeType": "Block",
"src": "31359:77:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3360,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3353,
"src": "31385:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"id": 3359,
"name": "_exists",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2552,
"src": "31377:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$_t_uint256_$returns$_t_bool_$",
"typeString": "function (uint256) view returns (bool)"
}
},
"id": 3361,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "31377:16:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 3358,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "31369:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 3362,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "31369:25:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3363,
"nodeType": "ExpressionStatement",
"src": "31369:25:13"
},
{
"expression": {
"argumentTypes": null,
"id": 3368,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 3364,
"name": "_tokenURIs",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3268,
"src": "31404:10:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_uint256_$_t_string_storage_$",
"typeString": "mapping(uint256 => string storage ref)"
}
},
"id": 3366,
"indexExpression": {
"argumentTypes": null,
"id": 3365,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3353,
"src": "31415:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": true,
"nodeType": "IndexAccess",
"src": "31404:19:13",
"typeDescriptions": {
"typeIdentifier": "t_string_storage",
"typeString": "string storage ref"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"id": 3367,
"name": "uri",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3355,
"src": "31426:3:13",
"typeDescriptions": {
"typeIdentifier": "t_string_memory_ptr",
"typeString": "string memory"
}
},
"src": "31404:25:13",
"typeDescriptions": {
"typeIdentifier": "t_string_storage",
"typeString": "string storage ref"
}
},
"id": 3369,
"nodeType": "ExpressionStatement",
"src": "31404:25:13"
}
]
},
"documentation": {
"id": 3351,
"nodeType": "StructuredDocumentation",
"src": "31061:226:13",
"text": " @dev Internal function to set the token URI for a given token\n Reverts if the token ID does not exist\n @param tokenId uint256 ID of the token to set its URI\n @param uri string URI to assign"
},
"id": 3371,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "_setTokenURI",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 3356,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3353,
"mutability": "mutable",
"name": "tokenId",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3371,
"src": "31314:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 3352,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "31314:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 3355,
"mutability": "mutable",
"name": "uri",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3371,
"src": "31331:17:13",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_string_memory_ptr",
"typeString": "string"
},
"typeName": {
"id": 3354,
"name": "string",
"nodeType": "ElementaryTypeName",
"src": "31331:6:13",
"typeDescriptions": {
"typeIdentifier": "t_string_storage_ptr",
"typeString": "string"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "31313:36:13"
},
"returnParameters": {
"id": 3357,
"nodeType": "ParameterList",
"parameters": [],
"src": "31359:0:13"
},
"scope": 3408,
"src": "31292:144:13",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 3402,
"nodeType": "Block",
"src": "31790:194:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3382,
"name": "owner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3374,
"src": "31822:5:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 3383,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3376,
"src": "31829:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"expression": {
"argumentTypes": null,
"id": 3379,
"name": "super",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": -25,
"src": "31800:5:13",
"typeDescriptions": {
"typeIdentifier": "t_super$_MockERC721Metadata_$3408",
"typeString": "contract super MockERC721Metadata"
}
},
"id": 3381,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "_burnMockERC721",
"nodeType": "MemberAccess",
"referencedDeclaration": 2686,
"src": "31800:21:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_uint256_$returns$__$",
"typeString": "function (address,uint256)"
}
},
"id": 3384,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "31800:37:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3385,
"nodeType": "ExpressionStatement",
"src": "31800:37:13"
},
{
"condition": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 3394,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 3388,
"name": "_tokenURIs",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3268,
"src": "31893:10:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_uint256_$_t_string_storage_$",
"typeString": "mapping(uint256 => string storage ref)"
}
},
"id": 3390,
"indexExpression": {
"argumentTypes": null,
"id": 3389,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3376,
"src": "31904:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "31893:19:13",
"typeDescriptions": {
"typeIdentifier": "t_string_storage",
"typeString": "string storage ref"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_string_storage",
"typeString": "string storage ref"
}
],
"id": 3387,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "ElementaryTypeNameExpression",
"src": "31887:5:13",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_bytes_storage_ptr_$",
"typeString": "type(bytes storage pointer)"
},
"typeName": {
"id": 3386,
"name": "bytes",
"nodeType": "ElementaryTypeName",
"src": "31887:5:13",
"typeDescriptions": {
"typeIdentifier": null,
"typeString": null
}
}
},
"id": 3391,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "31887:26:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_bytes_storage_ptr",
"typeString": "bytes storage pointer"
}
},
"id": 3392,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "length",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "31887:33:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "!=",
"rightExpression": {
"argumentTypes": null,
"hexValue": "30",
"id": 3393,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "31924:1:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
},
"src": "31887:38:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"falseBody": null,
"id": 3401,
"nodeType": "IfStatement",
"src": "31883:95:13",
"trueBody": {
"id": 3400,
"nodeType": "Block",
"src": "31927:51:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"id": 3398,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"nodeType": "UnaryOperation",
"operator": "delete",
"prefix": true,
"src": "31941:26:13",
"subExpression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 3395,
"name": "_tokenURIs",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3268,
"src": "31948:10:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_uint256_$_t_string_storage_$",
"typeString": "mapping(uint256 => string storage ref)"
}
},
"id": 3397,
"indexExpression": {
"argumentTypes": null,
"id": 3396,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3376,
"src": "31959:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": true,
"nodeType": "IndexAccess",
"src": "31948:19:13",
"typeDescriptions": {
"typeIdentifier": "t_string_storage",
"typeString": "string storage ref"
}
},
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3399,
"nodeType": "ExpressionStatement",
"src": "31941:26:13"
}
]
}
}
]
},
"documentation": {
"id": 3372,
"nodeType": "StructuredDocumentation",
"src": "31442:279:13",
"text": " @dev Internal function to burn a specific token\n Reverts if the token does not exist\n Deprecated, use _burn(uint256) instead\n @param owner owner of the token to burn\n @param tokenId uint256 ID of the token being burned by the msg.sender"
},
"id": 3403,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "_burn",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 3377,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3374,
"mutability": "mutable",
"name": "owner",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3403,
"src": "31741:13:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3373,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "31741:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 3376,
"mutability": "mutable",
"name": "tokenId",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3403,
"src": "31756:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 3375,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "31756:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "31740:32:13"
},
"returnParameters": {
"id": 3378,
"nodeType": "ParameterList",
"parameters": [],
"src": "31790:0:13"
},
"scope": 3408,
"src": "31726:258:13",
"stateMutability": "nonpayable",
"virtual": true,
"visibility": "internal"
},
{
"constant": false,
"id": 3407,
"mutability": "mutable",
"name": "______gap",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3408,
"src": "31990:29:13",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$50_storage",
"typeString": "uint256[50]"
},
"typeName": {
"baseType": {
"id": 3404,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "31990:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3406,
"length": {
"argumentTypes": null,
"hexValue": "3530",
"id": 3405,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "31998:2:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_50_by_1",
"typeString": "int_const 50"
},
"value": "50"
},
"nodeType": "ArrayTypeName",
"src": "31990:11:13",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$50_storage_ptr",
"typeString": "uint256[50]"
}
},
"value": null,
"visibility": "private"
}
],
"scope": 4171,
"src": "29228:2794:13"
},
{
"abstract": false,
"baseContracts": [],
"contractDependencies": [],
"contractKind": "library",
"documentation": {
"id": 3409,
"nodeType": "StructuredDocumentation",
"src": "32061:82:13",
"text": " @title Roles\n @dev Library for managing addresses assigned to a Role."
},
"fullyImplemented": true,
"id": 3507,
"linearizedBaseContracts": [
3507
],
"name": "Roles",
"nodeType": "ContractDefinition",
"nodes": [
{
"canonicalName": "Roles.Role",
"id": 3414,
"members": [
{
"constant": false,
"id": 3413,
"mutability": "mutable",
"name": "bearer",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3414,
"src": "32186:32:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_bool_$",
"typeString": "mapping(address => bool)"
},
"typeName": {
"id": 3412,
"keyType": {
"id": 3410,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "32195:7:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "Mapping",
"src": "32186:25:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_bool_$",
"typeString": "mapping(address => bool)"
},
"valueType": {
"id": 3411,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "32206:4:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
},
"value": null,
"visibility": "internal"
}
],
"name": "Role",
"nodeType": "StructDefinition",
"scope": 3507,
"src": "32164:61:13",
"visibility": "public"
},
{
"body": {
"id": 3447,
"nodeType": "Block",
"src": "32353:123:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"id": 3428,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 3423,
"name": "account",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3419,
"src": "32371:7:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "BinaryOperation",
"operator": "!=",
"rightExpression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"hexValue": "30",
"id": 3426,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "32390:1:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
}
],
"id": 3425,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "ElementaryTypeNameExpression",
"src": "32382:7:13",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_address_$",
"typeString": "type(address)"
},
"typeName": {
"id": 3424,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "32382:7:13",
"typeDescriptions": {
"typeIdentifier": null,
"typeString": null
}
}
},
"id": 3427,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "32382:10:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
}
},
"src": "32371:21:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 3422,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "32363:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 3429,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "32363:30:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3430,
"nodeType": "ExpressionStatement",
"src": "32363:30:13"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3436,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"nodeType": "UnaryOperation",
"operator": "!",
"prefix": true,
"src": "32411:19:13",
"subExpression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3433,
"name": "role",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3417,
"src": "32416:4:13",
"typeDescriptions": {
"typeIdentifier": "t_struct$_Role_$3414_storage_ptr",
"typeString": "struct Roles.Role storage pointer"
}
},
{
"argumentTypes": null,
"id": 3434,
"name": "account",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3419,
"src": "32422:7:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_struct$_Role_$3414_storage_ptr",
"typeString": "struct Roles.Role storage pointer"
},
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 3432,
"name": "has",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3506,
"src": "32412:3:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$_t_struct$_Role_$3414_storage_ptr_$_t_address_$returns$_t_bool_$",
"typeString": "function (struct Roles.Role storage pointer,address) view returns (bool)"
}
},
"id": 3435,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "32412:18:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 3431,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "32403:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 3437,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "32403:28:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3438,
"nodeType": "ExpressionStatement",
"src": "32403:28:13"
},
{
"expression": {
"argumentTypes": null,
"id": 3445,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 3439,
"name": "role",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3417,
"src": "32442:4:13",
"typeDescriptions": {
"typeIdentifier": "t_struct$_Role_$3414_storage_ptr",
"typeString": "struct Roles.Role storage pointer"
}
},
"id": 3442,
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"memberName": "bearer",
"nodeType": "MemberAccess",
"referencedDeclaration": 3413,
"src": "32442:11:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_bool_$",
"typeString": "mapping(address => bool)"
}
},
"id": 3443,
"indexExpression": {
"argumentTypes": null,
"id": 3441,
"name": "account",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3419,
"src": "32454:7:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": true,
"nodeType": "IndexAccess",
"src": "32442:20:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"hexValue": "74727565",
"id": 3444,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "bool",
"lValueRequested": false,
"nodeType": "Literal",
"src": "32465:4:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"value": "true"
},
"src": "32442:27:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"id": 3446,
"nodeType": "ExpressionStatement",
"src": "32442:27:13"
}
]
},
"documentation": {
"id": 3415,
"nodeType": "StructuredDocumentation",
"src": "32231:59:13",
"text": " @dev give an account access to this role"
},
"id": 3448,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "add",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 3420,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3417,
"mutability": "mutable",
"name": "role",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3448,
"src": "32308:17:13",
"stateVariable": false,
"storageLocation": "storage",
"typeDescriptions": {
"typeIdentifier": "t_struct$_Role_$3414_storage_ptr",
"typeString": "struct Roles.Role"
},
"typeName": {
"contractScope": null,
"id": 3416,
"name": "Role",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 3414,
"src": "32308:4:13",
"typeDescriptions": {
"typeIdentifier": "t_struct$_Role_$3414_storage_ptr",
"typeString": "struct Roles.Role"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 3419,
"mutability": "mutable",
"name": "account",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3448,
"src": "32327:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3418,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "32327:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "32307:36:13"
},
"returnParameters": {
"id": 3421,
"nodeType": "ParameterList",
"parameters": [],
"src": "32353:0:13"
},
"scope": 3507,
"src": "32295:181:13",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 3480,
"nodeType": "Block",
"src": "32611:123:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"id": 3462,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 3457,
"name": "account",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3453,
"src": "32629:7:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "BinaryOperation",
"operator": "!=",
"rightExpression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"hexValue": "30",
"id": 3460,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "32648:1:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
}
],
"id": 3459,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "ElementaryTypeNameExpression",
"src": "32640:7:13",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_address_$",
"typeString": "type(address)"
},
"typeName": {
"id": 3458,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "32640:7:13",
"typeDescriptions": {
"typeIdentifier": null,
"typeString": null
}
}
},
"id": 3461,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "32640:10:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
}
},
"src": "32629:21:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 3456,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "32621:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 3463,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "32621:30:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3464,
"nodeType": "ExpressionStatement",
"src": "32621:30:13"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3467,
"name": "role",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3451,
"src": "32673:4:13",
"typeDescriptions": {
"typeIdentifier": "t_struct$_Role_$3414_storage_ptr",
"typeString": "struct Roles.Role storage pointer"
}
},
{
"argumentTypes": null,
"id": 3468,
"name": "account",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3453,
"src": "32679:7:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_struct$_Role_$3414_storage_ptr",
"typeString": "struct Roles.Role storage pointer"
},
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 3466,
"name": "has",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3506,
"src": "32669:3:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$_t_struct$_Role_$3414_storage_ptr_$_t_address_$returns$_t_bool_$",
"typeString": "function (struct Roles.Role storage pointer,address) view returns (bool)"
}
},
"id": 3469,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "32669:18:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 3465,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "32661:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 3470,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "32661:27:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3471,
"nodeType": "ExpressionStatement",
"src": "32661:27:13"
},
{
"expression": {
"argumentTypes": null,
"id": 3478,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 3472,
"name": "role",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3451,
"src": "32699:4:13",
"typeDescriptions": {
"typeIdentifier": "t_struct$_Role_$3414_storage_ptr",
"typeString": "struct Roles.Role storage pointer"
}
},
"id": 3475,
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"memberName": "bearer",
"nodeType": "MemberAccess",
"referencedDeclaration": 3413,
"src": "32699:11:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_bool_$",
"typeString": "mapping(address => bool)"
}
},
"id": 3476,
"indexExpression": {
"argumentTypes": null,
"id": 3474,
"name": "account",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3453,
"src": "32711:7:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": true,
"nodeType": "IndexAccess",
"src": "32699:20:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"hexValue": "66616c7365",
"id": 3477,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "bool",
"lValueRequested": false,
"nodeType": "Literal",
"src": "32722:5:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"value": "false"
},
"src": "32699:28:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"id": 3479,
"nodeType": "ExpressionStatement",
"src": "32699:28:13"
}
]
},
"documentation": {
"id": 3449,
"nodeType": "StructuredDocumentation",
"src": "32482:63:13",
"text": " @dev remove an account's access to this role"
},
"id": 3481,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "remove",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 3454,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3451,
"mutability": "mutable",
"name": "role",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3481,
"src": "32566:17:13",
"stateVariable": false,
"storageLocation": "storage",
"typeDescriptions": {
"typeIdentifier": "t_struct$_Role_$3414_storage_ptr",
"typeString": "struct Roles.Role"
},
"typeName": {
"contractScope": null,
"id": 3450,
"name": "Role",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 3414,
"src": "32566:4:13",
"typeDescriptions": {
"typeIdentifier": "t_struct$_Role_$3414_storage_ptr",
"typeString": "struct Roles.Role"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 3453,
"mutability": "mutable",
"name": "account",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3481,
"src": "32585:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3452,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "32585:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "32565:36:13"
},
"returnParameters": {
"id": 3455,
"nodeType": "ParameterList",
"parameters": [],
"src": "32611:0:13"
},
"scope": 3507,
"src": "32550:184:13",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 3505,
"nodeType": "Block",
"src": "32900:84:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"id": 3497,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 3492,
"name": "account",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3486,
"src": "32918:7:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "BinaryOperation",
"operator": "!=",
"rightExpression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"hexValue": "30",
"id": 3495,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "32937:1:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
}
],
"id": 3494,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "ElementaryTypeNameExpression",
"src": "32929:7:13",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_address_$",
"typeString": "type(address)"
},
"typeName": {
"id": 3493,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "32929:7:13",
"typeDescriptions": {
"typeIdentifier": null,
"typeString": null
}
}
},
"id": 3496,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "32929:10:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
}
},
"src": "32918:21:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 3491,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "32910:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 3498,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "32910:30:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3499,
"nodeType": "ExpressionStatement",
"src": "32910:30:13"
},
{
"expression": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 3500,
"name": "role",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3484,
"src": "32957:4:13",
"typeDescriptions": {
"typeIdentifier": "t_struct$_Role_$3414_storage_ptr",
"typeString": "struct Roles.Role storage pointer"
}
},
"id": 3501,
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"memberName": "bearer",
"nodeType": "MemberAccess",
"referencedDeclaration": 3413,
"src": "32957:11:13",
"typeDescriptions": {
"typeIdentifier": "t_mapping$_t_address_$_t_bool_$",
"typeString": "mapping(address => bool)"
}
},
"id": 3503,
"indexExpression": {
"argumentTypes": null,
"id": 3502,
"name": "account",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3486,
"src": "32969:7:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "32957:20:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"functionReturnParameters": 3490,
"id": 3504,
"nodeType": "Return",
"src": "32950:27:13"
}
]
},
"documentation": {
"id": 3482,
"nodeType": "StructuredDocumentation",
"src": "32740:77:13",
"text": " @dev check if an account has this role\n @return bool"
},
"id": 3506,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "has",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 3487,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3484,
"mutability": "mutable",
"name": "role",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3506,
"src": "32835:17:13",
"stateVariable": false,
"storageLocation": "storage",
"typeDescriptions": {
"typeIdentifier": "t_struct$_Role_$3414_storage_ptr",
"typeString": "struct Roles.Role"
},
"typeName": {
"contractScope": null,
"id": 3483,
"name": "Role",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 3414,
"src": "32835:4:13",
"typeDescriptions": {
"typeIdentifier": "t_struct$_Role_$3414_storage_ptr",
"typeString": "struct Roles.Role"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 3486,
"mutability": "mutable",
"name": "account",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3506,
"src": "32854:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3485,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "32854:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "32834:36:13"
},
"returnParameters": {
"id": 3490,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3489,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3506,
"src": "32894:4:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 3488,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "32894:4:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "32893:6:13"
},
"scope": 3507,
"src": "32822:162:13",
"stateMutability": "view",
"virtual": false,
"visibility": "internal"
}
],
"scope": 4171,
"src": "32144:842:13"
},
{
"abstract": false,
"baseContracts": [
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 3508,
"name": "Initializable",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 74,
"src": "33062:13:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_Initializable_$74",
"typeString": "contract Initializable"
}
},
"id": 3509,
"nodeType": "InheritanceSpecifier",
"src": "33062:13:13"
}
],
"contractDependencies": [
74
],
"contractKind": "contract",
"documentation": null,
"fullyImplemented": true,
"id": 3622,
"linearizedBaseContracts": [
3622,
74
],
"name": "MinterRole",
"nodeType": "ContractDefinition",
"nodes": [
{
"id": 3512,
"libraryName": {
"contractScope": null,
"id": 3510,
"name": "Roles",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 3507,
"src": "33088:5:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_Roles_$3507",
"typeString": "library Roles"
}
},
"nodeType": "UsingForDirective",
"src": "33082:27:13",
"typeName": {
"contractScope": null,
"id": 3511,
"name": "Roles.Role",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 3414,
"src": "33098:10:13",
"typeDescriptions": {
"typeIdentifier": "t_struct$_Role_$3414_storage_ptr",
"typeString": "struct Roles.Role"
}
}
},
{
"anonymous": false,
"documentation": null,
"id": 3516,
"name": "MinterAdded",
"nodeType": "EventDefinition",
"parameters": {
"id": 3515,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3514,
"indexed": true,
"mutability": "mutable",
"name": "account",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3516,
"src": "33133:23:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3513,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "33133:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "33132:25:13"
},
"src": "33115:43:13"
},
{
"anonymous": false,
"documentation": null,
"id": 3520,
"name": "MinterRemoved",
"nodeType": "EventDefinition",
"parameters": {
"id": 3519,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3518,
"indexed": true,
"mutability": "mutable",
"name": "account",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3520,
"src": "33183:23:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3517,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "33183:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "33182:25:13"
},
"src": "33163:45:13"
},
{
"constant": false,
"id": 3522,
"mutability": "mutable",
"name": "_minters",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3622,
"src": "33214:27:13",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_struct$_Role_$3414_storage",
"typeString": "struct Roles.Role"
},
"typeName": {
"contractScope": null,
"id": 3521,
"name": "Roles.Role",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 3414,
"src": "33214:10:13",
"typeDescriptions": {
"typeIdentifier": "t_struct$_Role_$3414_storage_ptr",
"typeString": "struct Roles.Role"
}
},
"value": null,
"visibility": "private"
},
{
"body": {
"id": 3539,
"nodeType": "Block",
"src": "33314:82:13",
"statements": [
{
"condition": {
"argumentTypes": null,
"id": 3532,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"nodeType": "UnaryOperation",
"operator": "!",
"prefix": true,
"src": "33328:17:13",
"subExpression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3530,
"name": "sender",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3524,
"src": "33338:6:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 3529,
"name": "isMinter",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3564,
"src": "33329:8:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$_t_address_$returns$_t_bool_$",
"typeString": "function (address) view returns (bool)"
}
},
"id": 3531,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "33329:16:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"falseBody": null,
"id": 3538,
"nodeType": "IfStatement",
"src": "33324:66:13",
"trueBody": {
"id": 3537,
"nodeType": "Block",
"src": "33347:43:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3534,
"name": "sender",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3524,
"src": "33372:6:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 3533,
"name": "_addMinter",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3601,
"src": "33361:10:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$returns$__$",
"typeString": "function (address)"
}
},
"id": 3535,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "33361:18:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3536,
"nodeType": "ExpressionStatement",
"src": "33361:18:13"
}
]
}
}
]
},
"documentation": null,
"functionSelector": "fb7cb301",
"id": 3540,
"implemented": true,
"kind": "function",
"modifiers": [
{
"arguments": null,
"id": 3527,
"modifierName": {
"argumentTypes": null,
"id": 3526,
"name": "initializer",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 47,
"src": "33301:11:13",
"typeDescriptions": {
"typeIdentifier": "t_modifier$__$",
"typeString": "modifier ()"
}
},
"nodeType": "ModifierInvocation",
"src": "33301:11:13"
}
],
"name": "initializeMinterRole",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 3525,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3524,
"mutability": "mutable",
"name": "sender",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3540,
"src": "33278:14:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3523,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "33278:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "33277:16:13"
},
"returnParameters": {
"id": 3528,
"nodeType": "ParameterList",
"parameters": [],
"src": "33314:0:13"
},
"scope": 3622,
"src": "33248:148:13",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
{
"body": {
"id": 3550,
"nodeType": "Block",
"src": "33424:57:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 3544,
"name": "msg",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": -15,
"src": "33451:3:13",
"typeDescriptions": {
"typeIdentifier": "t_magic_message",
"typeString": "msg"
}
},
"id": 3545,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "sender",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "33451:10:13",
"typeDescriptions": {
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
}
],
"id": 3543,
"name": "isMinter",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3564,
"src": "33442:8:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$_t_address_$returns$_t_bool_$",
"typeString": "function (address) view returns (bool)"
}
},
"id": 3546,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "33442:20:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 3542,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "33434:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 3547,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "33434:29:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3548,
"nodeType": "ExpressionStatement",
"src": "33434:29:13"
},
{
"id": 3549,
"nodeType": "PlaceholderStatement",
"src": "33473:1:13"
}
]
},
"documentation": null,
"id": 3551,
"name": "onlyMinter",
"nodeType": "ModifierDefinition",
"overrides": null,
"parameters": {
"id": 3541,
"nodeType": "ParameterList",
"parameters": [],
"src": "33421:2:13"
},
"src": "33402:79:13",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 3563,
"nodeType": "Block",
"src": "33549:45:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3560,
"name": "account",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3553,
"src": "33579:7:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"expression": {
"argumentTypes": null,
"id": 3558,
"name": "_minters",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3522,
"src": "33566:8:13",
"typeDescriptions": {
"typeIdentifier": "t_struct$_Role_$3414_storage",
"typeString": "struct Roles.Role storage ref"
}
},
"id": 3559,
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"memberName": "has",
"nodeType": "MemberAccess",
"referencedDeclaration": 3506,
"src": "33566:12:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$_t_struct$_Role_$3414_storage_ptr_$_t_address_$returns$_t_bool_$bound_to$_t_struct$_Role_$3414_storage_ptr_$",
"typeString": "function (struct Roles.Role storage pointer,address) view returns (bool)"
}
},
"id": 3561,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "33566:21:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"functionReturnParameters": 3557,
"id": 3562,
"nodeType": "Return",
"src": "33559:28:13"
}
]
},
"documentation": null,
"functionSelector": "aa271e1a",
"id": 3564,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "isMinter",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 3554,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3553,
"mutability": "mutable",
"name": "account",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3564,
"src": "33505:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3552,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "33505:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "33504:17:13"
},
"returnParameters": {
"id": 3557,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3556,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3564,
"src": "33543:4:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 3555,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "33543:4:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "33542:6:13"
},
"scope": 3622,
"src": "33487:107:13",
"stateMutability": "view",
"virtual": false,
"visibility": "public"
},
{
"body": {
"id": 3575,
"nodeType": "Block",
"src": "33654:36:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3572,
"name": "account",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3566,
"src": "33675:7:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 3571,
"name": "_addMinter",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3601,
"src": "33664:10:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$returns$__$",
"typeString": "function (address)"
}
},
"id": 3573,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "33664:19:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3574,
"nodeType": "ExpressionStatement",
"src": "33664:19:13"
}
]
},
"documentation": null,
"functionSelector": "983b2d56",
"id": 3576,
"implemented": true,
"kind": "function",
"modifiers": [
{
"arguments": null,
"id": 3569,
"modifierName": {
"argumentTypes": null,
"id": 3568,
"name": "onlyMinter",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3551,
"src": "33643:10:13",
"typeDescriptions": {
"typeIdentifier": "t_modifier$__$",
"typeString": "modifier ()"
}
},
"nodeType": "ModifierInvocation",
"src": "33643:10:13"
}
],
"name": "addMinter",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 3567,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3566,
"mutability": "mutable",
"name": "account",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3576,
"src": "33619:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3565,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "33619:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "33618:17:13"
},
"returnParameters": {
"id": 3570,
"nodeType": "ParameterList",
"parameters": [],
"src": "33654:0:13"
},
"scope": 3622,
"src": "33600:90:13",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
{
"body": {
"id": 3584,
"nodeType": "Block",
"src": "33729:42:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 3580,
"name": "msg",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": -15,
"src": "33753:3:13",
"typeDescriptions": {
"typeIdentifier": "t_magic_message",
"typeString": "msg"
}
},
"id": 3581,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "sender",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "33753:10:13",
"typeDescriptions": {
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
}
],
"id": 3579,
"name": "_removeMinter",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3617,
"src": "33739:13:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$returns$__$",
"typeString": "function (address)"
}
},
"id": 3582,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "33739:25:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3583,
"nodeType": "ExpressionStatement",
"src": "33739:25:13"
}
]
},
"documentation": null,
"functionSelector": "98650275",
"id": 3585,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "renounceMinter",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 3577,
"nodeType": "ParameterList",
"parameters": [],
"src": "33719:2:13"
},
"returnParameters": {
"id": 3578,
"nodeType": "ParameterList",
"parameters": [],
"src": "33729:0:13"
},
"scope": 3622,
"src": "33696:75:13",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
{
"body": {
"id": 3600,
"nodeType": "Block",
"src": "33823:73:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3593,
"name": "account",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3587,
"src": "33846:7:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"expression": {
"argumentTypes": null,
"id": 3590,
"name": "_minters",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3522,
"src": "33833:8:13",
"typeDescriptions": {
"typeIdentifier": "t_struct$_Role_$3414_storage",
"typeString": "struct Roles.Role storage ref"
}
},
"id": 3592,
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"memberName": "add",
"nodeType": "MemberAccess",
"referencedDeclaration": 3448,
"src": "33833:12:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_struct$_Role_$3414_storage_ptr_$_t_address_$returns$__$bound_to$_t_struct$_Role_$3414_storage_ptr_$",
"typeString": "function (struct Roles.Role storage pointer,address)"
}
},
"id": 3594,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "33833:21:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3595,
"nodeType": "ExpressionStatement",
"src": "33833:21:13"
},
{
"eventCall": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3597,
"name": "account",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3587,
"src": "33881:7:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 3596,
"name": "MinterAdded",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3516,
"src": "33869:11:13",
"typeDescriptions": {
"typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$",
"typeString": "function (address)"
}
},
"id": 3598,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "33869:20:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3599,
"nodeType": "EmitStatement",
"src": "33864:25:13"
}
]
},
"documentation": null,
"id": 3601,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "_addMinter",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 3588,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3587,
"mutability": "mutable",
"name": "account",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3601,
"src": "33797:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3586,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "33797:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "33796:17:13"
},
"returnParameters": {
"id": 3589,
"nodeType": "ParameterList",
"parameters": [],
"src": "33823:0:13"
},
"scope": 3622,
"src": "33777:119:13",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 3616,
"nodeType": "Block",
"src": "33951:78:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3609,
"name": "account",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3603,
"src": "33977:7:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"expression": {
"argumentTypes": null,
"id": 3606,
"name": "_minters",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3522,
"src": "33961:8:13",
"typeDescriptions": {
"typeIdentifier": "t_struct$_Role_$3414_storage",
"typeString": "struct Roles.Role storage ref"
}
},
"id": 3608,
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"memberName": "remove",
"nodeType": "MemberAccess",
"referencedDeclaration": 3481,
"src": "33961:15:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_struct$_Role_$3414_storage_ptr_$_t_address_$returns$__$bound_to$_t_struct$_Role_$3414_storage_ptr_$",
"typeString": "function (struct Roles.Role storage pointer,address)"
}
},
"id": 3610,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "33961:24:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3611,
"nodeType": "ExpressionStatement",
"src": "33961:24:13"
},
{
"eventCall": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3613,
"name": "account",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3603,
"src": "34014:7:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 3612,
"name": "MinterRemoved",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3520,
"src": "34000:13:13",
"typeDescriptions": {
"typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$",
"typeString": "function (address)"
}
},
"id": 3614,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "34000:22:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3615,
"nodeType": "EmitStatement",
"src": "33995:27:13"
}
]
},
"documentation": null,
"id": 3617,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "_removeMinter",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 3604,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3603,
"mutability": "mutable",
"name": "account",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3617,
"src": "33925:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3602,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "33925:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "33924:17:13"
},
"returnParameters": {
"id": 3605,
"nodeType": "ParameterList",
"parameters": [],
"src": "33951:0:13"
},
"scope": 3622,
"src": "33902:127:13",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "internal"
},
{
"constant": false,
"id": 3621,
"mutability": "mutable",
"name": "______gap",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3622,
"src": "34035:29:13",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$50_storage",
"typeString": "uint256[50]"
},
"typeName": {
"baseType": {
"id": 3618,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "34035:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3620,
"length": {
"argumentTypes": null,
"hexValue": "3530",
"id": 3619,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "34043:2:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_50_by_1",
"typeString": "int_const 50"
},
"value": "50"
},
"nodeType": "ArrayTypeName",
"src": "34035:11:13",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$50_storage_ptr",
"typeString": "uint256[50]"
}
},
"value": null,
"visibility": "private"
}
],
"scope": 4171,
"src": "33039:1028:13"
},
{
"abstract": false,
"baseContracts": [
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 3624,
"name": "Initializable",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 74,
"src": "34272:13:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_Initializable_$74",
"typeString": "contract Initializable"
}
},
"id": 3625,
"nodeType": "InheritanceSpecifier",
"src": "34272:13:13"
},
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 3626,
"name": "MockERC721",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 2838,
"src": "34287:10:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_MockERC721_$2838",
"typeString": "contract MockERC721"
}
},
"id": 3627,
"nodeType": "InheritanceSpecifier",
"src": "34287:10:13"
},
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 3628,
"name": "MockERC721Metadata",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 3408,
"src": "34299:18:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_MockERC721Metadata_$3408",
"typeString": "contract MockERC721Metadata"
}
},
"id": 3629,
"nodeType": "InheritanceSpecifier",
"src": "34299:18:13"
},
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 3630,
"name": "MinterRole",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 3622,
"src": "34319:10:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_MinterRole_$3622",
"typeString": "contract MinterRole"
}
},
"id": 3631,
"nodeType": "InheritanceSpecifier",
"src": "34319:10:13"
}
],
"contractDependencies": [
74,
1976,
2006,
2235,
2838,
3252,
3408,
3622
],
"contractKind": "contract",
"documentation": {
"id": 3623,
"nodeType": "StructuredDocumentation",
"src": "34141:91:13",
"text": " @title MockERC721MetadataMintable\n @dev MockERC721 minting logic with metadata"
},
"fullyImplemented": true,
"id": 3689,
"linearizedBaseContracts": [
3689,
3622,
3408,
3252,
2838,
2006,
2235,
1976,
74
],
"name": "MockERC721MetadataMintable",
"nodeType": "ContractDefinition",
"nodes": [
{
"body": {
"id": 3656,
"nodeType": "Block",
"src": "34417:176:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [],
"expression": {
"argumentTypes": [],
"expression": {
"argumentTypes": null,
"id": 3639,
"name": "MockERC721",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2838,
"src": "34435:10:13",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_contract$_MockERC721_$2838_$",
"typeString": "type(contract MockERC721)"
}
},
"id": 3640,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "_hasBeenInitializedMockERC721",
"nodeType": "MemberAccess",
"referencedDeclaration": 2297,
"src": "34435:40:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$__$returns$_t_bool_$",
"typeString": "function () view returns (bool)"
}
},
"id": 3641,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "34435:42:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 3638,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "34427:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 3642,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "34427:51:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3643,
"nodeType": "ExpressionStatement",
"src": "34427:51:13"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [],
"expression": {
"argumentTypes": [],
"expression": {
"argumentTypes": null,
"id": 3645,
"name": "MockERC721Metadata",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3408,
"src": "34496:18:13",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_contract$_MockERC721Metadata_$3408_$",
"typeString": "type(contract MockERC721Metadata)"
}
},
"id": 3646,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "_hasBeenInitialized",
"nodeType": "MemberAccess",
"referencedDeclaration": 3310,
"src": "34496:38:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$__$returns$_t_bool_$",
"typeString": "function () view returns (bool)"
}
},
"id": 3647,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "34496:40:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 3644,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "34488:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 3648,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "34488:49:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3649,
"nodeType": "ExpressionStatement",
"src": "34488:49:13"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3653,
"name": "sender",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3633,
"src": "34579:6:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"expression": {
"argumentTypes": null,
"id": 3650,
"name": "MinterRole",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3622,
"src": "34547:10:13",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_contract$_MinterRole_$3622_$",
"typeString": "type(contract MinterRole)"
}
},
"id": 3652,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "initializeMinterRole",
"nodeType": "MemberAccess",
"referencedDeclaration": 3540,
"src": "34547:31:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$returns$__$",
"typeString": "function (address)"
}
},
"id": 3654,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "34547:39:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3655,
"nodeType": "ExpressionStatement",
"src": "34547:39:13"
}
]
},
"documentation": null,
"functionSelector": "ec1bc004",
"id": 3657,
"implemented": true,
"kind": "function",
"modifiers": [
{
"arguments": null,
"id": 3636,
"modifierName": {
"argumentTypes": null,
"id": 3635,
"name": "initializer",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 47,
"src": "34405:11:13",
"typeDescriptions": {
"typeIdentifier": "t_modifier$__$",
"typeString": "modifier ()"
}
},
"nodeType": "ModifierInvocation",
"src": "34405:11:13"
}
],
"name": "initializeMockERC721MetadataMintable",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 3634,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3633,
"mutability": "mutable",
"name": "sender",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3657,
"src": "34382:14:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3632,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "34382:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "34381:16:13"
},
"returnParameters": {
"id": 3637,
"nodeType": "ParameterList",
"parameters": [],
"src": "34417:0:13"
},
"scope": 3689,
"src": "34336:257:13",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
{
"body": {
"id": 3683,
"nodeType": "Block",
"src": "35161:107:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3672,
"name": "to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3660,
"src": "35187:2:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 3673,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3662,
"src": "35191:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"id": 3671,
"name": "_mintMockERC721",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2636,
"src": "35171:15:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_uint256_$returns$__$",
"typeString": "function (address,uint256)"
}
},
"id": 3674,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "35171:28:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3675,
"nodeType": "ExpressionStatement",
"src": "35171:28:13"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3677,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3662,
"src": "35222:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
{
"argumentTypes": null,
"id": 3678,
"name": "tokenURI",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3664,
"src": "35231:8:13",
"typeDescriptions": {
"typeIdentifier": "t_string_memory_ptr",
"typeString": "string memory"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
{
"typeIdentifier": "t_string_memory_ptr",
"typeString": "string memory"
}
],
"id": 3676,
"name": "_setTokenURI",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3371,
"src": "35209:12:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_uint256_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (uint256,string memory)"
}
},
"id": 3679,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "35209:31:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3680,
"nodeType": "ExpressionStatement",
"src": "35209:31:13"
},
{
"expression": {
"argumentTypes": null,
"hexValue": "74727565",
"id": 3681,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "bool",
"lValueRequested": false,
"nodeType": "Literal",
"src": "35257:4:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"value": "true"
},
"functionReturnParameters": 3670,
"id": 3682,
"nodeType": "Return",
"src": "35250:11:13"
}
]
},
"documentation": {
"id": 3658,
"nodeType": "StructuredDocumentation",
"src": "34756:288:13",
"text": " @dev Function to mint tokens\n @param to The address that will receive the minted tokens.\n @param tokenId The token id to mint.\n @param tokenURI The token URI of the minted token.\n @return A boolean that indicates if the operation was successful."
},
"functionSelector": "50bb4e7f",
"id": 3684,
"implemented": true,
"kind": "function",
"modifiers": [
{
"arguments": null,
"id": 3667,
"modifierName": {
"argumentTypes": null,
"id": 3666,
"name": "onlyMinter",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3551,
"src": "35135:10:13",
"typeDescriptions": {
"typeIdentifier": "t_modifier$__$",
"typeString": "modifier ()"
}
},
"nodeType": "ModifierInvocation",
"src": "35135:10:13"
}
],
"name": "mintWithTokenURI",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 3665,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3660,
"mutability": "mutable",
"name": "to",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3684,
"src": "35075:10:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3659,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "35075:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 3662,
"mutability": "mutable",
"name": "tokenId",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3684,
"src": "35087:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 3661,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "35087:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 3664,
"mutability": "mutable",
"name": "tokenURI",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3684,
"src": "35104:22:13",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_string_memory_ptr",
"typeString": "string"
},
"typeName": {
"id": 3663,
"name": "string",
"nodeType": "ElementaryTypeName",
"src": "35104:6:13",
"typeDescriptions": {
"typeIdentifier": "t_string_storage_ptr",
"typeString": "string"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "35074:53:13"
},
"returnParameters": {
"id": 3670,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3669,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3684,
"src": "35155:4:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 3668,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "35155:4:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "35154:6:13"
},
"scope": 3689,
"src": "35049:219:13",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
{
"constant": false,
"id": 3688,
"mutability": "mutable",
"name": "______gap",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3689,
"src": "35274:29:13",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$50_storage",
"typeString": "uint256[50]"
},
"typeName": {
"baseType": {
"id": 3685,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "35274:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3687,
"length": {
"argumentTypes": null,
"hexValue": "3530",
"id": 3686,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "35282:2:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_50_by_1",
"typeString": "int_const 50"
},
"value": "50"
},
"nodeType": "ArrayTypeName",
"src": "35274:11:13",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$50_storage_ptr",
"typeString": "uint256[50]"
}
},
"value": null,
"visibility": "private"
}
],
"scope": 4171,
"src": "34233:1073:13"
},
{
"abstract": false,
"baseContracts": [
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 3690,
"name": "Initializable",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 74,
"src": "35382:13:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_Initializable_$74",
"typeString": "contract Initializable"
}
},
"id": 3691,
"nodeType": "InheritanceSpecifier",
"src": "35382:13:13"
}
],
"contractDependencies": [
74
],
"contractKind": "contract",
"documentation": null,
"fullyImplemented": true,
"id": 3804,
"linearizedBaseContracts": [
3804,
74
],
"name": "PauserRole",
"nodeType": "ContractDefinition",
"nodes": [
{
"id": 3694,
"libraryName": {
"contractScope": null,
"id": 3692,
"name": "Roles",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 3507,
"src": "35408:5:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_Roles_$3507",
"typeString": "library Roles"
}
},
"nodeType": "UsingForDirective",
"src": "35402:27:13",
"typeName": {
"contractScope": null,
"id": 3693,
"name": "Roles.Role",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 3414,
"src": "35418:10:13",
"typeDescriptions": {
"typeIdentifier": "t_struct$_Role_$3414_storage_ptr",
"typeString": "struct Roles.Role"
}
}
},
{
"anonymous": false,
"documentation": null,
"id": 3698,
"name": "PauserAdded",
"nodeType": "EventDefinition",
"parameters": {
"id": 3697,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3696,
"indexed": true,
"mutability": "mutable",
"name": "account",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3698,
"src": "35453:23:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3695,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "35453:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "35452:25:13"
},
"src": "35435:43:13"
},
{
"anonymous": false,
"documentation": null,
"id": 3702,
"name": "PauserRemoved",
"nodeType": "EventDefinition",
"parameters": {
"id": 3701,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3700,
"indexed": true,
"mutability": "mutable",
"name": "account",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3702,
"src": "35503:23:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3699,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "35503:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "35502:25:13"
},
"src": "35483:45:13"
},
{
"constant": false,
"id": 3704,
"mutability": "mutable",
"name": "_pausers",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3804,
"src": "35534:27:13",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_struct$_Role_$3414_storage",
"typeString": "struct Roles.Role"
},
"typeName": {
"contractScope": null,
"id": 3703,
"name": "Roles.Role",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 3414,
"src": "35534:10:13",
"typeDescriptions": {
"typeIdentifier": "t_struct$_Role_$3414_storage_ptr",
"typeString": "struct Roles.Role"
}
},
"value": null,
"visibility": "private"
},
{
"body": {
"id": 3721,
"nodeType": "Block",
"src": "35633:82:13",
"statements": [
{
"condition": {
"argumentTypes": null,
"id": 3714,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"nodeType": "UnaryOperation",
"operator": "!",
"prefix": true,
"src": "35647:17:13",
"subExpression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3712,
"name": "sender",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3706,
"src": "35657:6:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 3711,
"name": "isPauser",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3746,
"src": "35648:8:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$_t_address_$returns$_t_bool_$",
"typeString": "function (address) view returns (bool)"
}
},
"id": 3713,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "35648:16:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"falseBody": null,
"id": 3720,
"nodeType": "IfStatement",
"src": "35643:66:13",
"trueBody": {
"id": 3719,
"nodeType": "Block",
"src": "35666:43:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3716,
"name": "sender",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3706,
"src": "35691:6:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 3715,
"name": "_addPauser",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3783,
"src": "35680:10:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$returns$__$",
"typeString": "function (address)"
}
},
"id": 3717,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "35680:18:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3718,
"nodeType": "ExpressionStatement",
"src": "35680:18:13"
}
]
}
}
]
},
"documentation": null,
"functionSelector": "29bfda9e",
"id": 3722,
"implemented": true,
"kind": "function",
"modifiers": [
{
"arguments": null,
"id": 3709,
"modifierName": {
"argumentTypes": null,
"id": 3708,
"name": "initializer",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 47,
"src": "35621:11:13",
"typeDescriptions": {
"typeIdentifier": "t_modifier$__$",
"typeString": "modifier ()"
}
},
"nodeType": "ModifierInvocation",
"src": "35621:11:13"
}
],
"name": "initializePauserRole",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 3707,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3706,
"mutability": "mutable",
"name": "sender",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3722,
"src": "35598:14:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3705,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "35598:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "35597:16:13"
},
"returnParameters": {
"id": 3710,
"nodeType": "ParameterList",
"parameters": [],
"src": "35633:0:13"
},
"scope": 3804,
"src": "35568:147:13",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
{
"body": {
"id": 3732,
"nodeType": "Block",
"src": "35743:57:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 3726,
"name": "msg",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": -15,
"src": "35770:3:13",
"typeDescriptions": {
"typeIdentifier": "t_magic_message",
"typeString": "msg"
}
},
"id": 3727,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "sender",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "35770:10:13",
"typeDescriptions": {
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
}
],
"id": 3725,
"name": "isPauser",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3746,
"src": "35761:8:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$_t_address_$returns$_t_bool_$",
"typeString": "function (address) view returns (bool)"
}
},
"id": 3728,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "35761:20:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 3724,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "35753:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 3729,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "35753:29:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3730,
"nodeType": "ExpressionStatement",
"src": "35753:29:13"
},
{
"id": 3731,
"nodeType": "PlaceholderStatement",
"src": "35792:1:13"
}
]
},
"documentation": null,
"id": 3733,
"name": "onlyPauser",
"nodeType": "ModifierDefinition",
"overrides": null,
"parameters": {
"id": 3723,
"nodeType": "ParameterList",
"parameters": [],
"src": "35740:2:13"
},
"src": "35721:79:13",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 3745,
"nodeType": "Block",
"src": "35868:45:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3742,
"name": "account",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3735,
"src": "35898:7:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"expression": {
"argumentTypes": null,
"id": 3740,
"name": "_pausers",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3704,
"src": "35885:8:13",
"typeDescriptions": {
"typeIdentifier": "t_struct$_Role_$3414_storage",
"typeString": "struct Roles.Role storage ref"
}
},
"id": 3741,
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"memberName": "has",
"nodeType": "MemberAccess",
"referencedDeclaration": 3506,
"src": "35885:12:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$_t_struct$_Role_$3414_storage_ptr_$_t_address_$returns$_t_bool_$bound_to$_t_struct$_Role_$3414_storage_ptr_$",
"typeString": "function (struct Roles.Role storage pointer,address) view returns (bool)"
}
},
"id": 3743,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "35885:21:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"functionReturnParameters": 3739,
"id": 3744,
"nodeType": "Return",
"src": "35878:28:13"
}
]
},
"documentation": null,
"functionSelector": "46fbf68e",
"id": 3746,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "isPauser",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 3736,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3735,
"mutability": "mutable",
"name": "account",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3746,
"src": "35824:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3734,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "35824:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "35823:17:13"
},
"returnParameters": {
"id": 3739,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3738,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3746,
"src": "35862:4:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 3737,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "35862:4:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "35861:6:13"
},
"scope": 3804,
"src": "35806:107:13",
"stateMutability": "view",
"virtual": false,
"visibility": "public"
},
{
"body": {
"id": 3757,
"nodeType": "Block",
"src": "35973:36:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3754,
"name": "account",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3748,
"src": "35994:7:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 3753,
"name": "_addPauser",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3783,
"src": "35983:10:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$returns$__$",
"typeString": "function (address)"
}
},
"id": 3755,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "35983:19:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3756,
"nodeType": "ExpressionStatement",
"src": "35983:19:13"
}
]
},
"documentation": null,
"functionSelector": "82dc1ec4",
"id": 3758,
"implemented": true,
"kind": "function",
"modifiers": [
{
"arguments": null,
"id": 3751,
"modifierName": {
"argumentTypes": null,
"id": 3750,
"name": "onlyPauser",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3733,
"src": "35962:10:13",
"typeDescriptions": {
"typeIdentifier": "t_modifier$__$",
"typeString": "modifier ()"
}
},
"nodeType": "ModifierInvocation",
"src": "35962:10:13"
}
],
"name": "addPauser",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 3749,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3748,
"mutability": "mutable",
"name": "account",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3758,
"src": "35938:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3747,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "35938:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "35937:17:13"
},
"returnParameters": {
"id": 3752,
"nodeType": "ParameterList",
"parameters": [],
"src": "35973:0:13"
},
"scope": 3804,
"src": "35919:90:13",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
{
"body": {
"id": 3766,
"nodeType": "Block",
"src": "36048:42:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 3762,
"name": "msg",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": -15,
"src": "36072:3:13",
"typeDescriptions": {
"typeIdentifier": "t_magic_message",
"typeString": "msg"
}
},
"id": 3763,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "sender",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "36072:10:13",
"typeDescriptions": {
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
}
],
"id": 3761,
"name": "_removePauser",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3799,
"src": "36058:13:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$returns$__$",
"typeString": "function (address)"
}
},
"id": 3764,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "36058:25:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3765,
"nodeType": "ExpressionStatement",
"src": "36058:25:13"
}
]
},
"documentation": null,
"functionSelector": "6ef8d66d",
"id": 3767,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "renouncePauser",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 3759,
"nodeType": "ParameterList",
"parameters": [],
"src": "36038:2:13"
},
"returnParameters": {
"id": 3760,
"nodeType": "ParameterList",
"parameters": [],
"src": "36048:0:13"
},
"scope": 3804,
"src": "36015:75:13",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
{
"body": {
"id": 3782,
"nodeType": "Block",
"src": "36142:73:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3775,
"name": "account",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3769,
"src": "36165:7:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"expression": {
"argumentTypes": null,
"id": 3772,
"name": "_pausers",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3704,
"src": "36152:8:13",
"typeDescriptions": {
"typeIdentifier": "t_struct$_Role_$3414_storage",
"typeString": "struct Roles.Role storage ref"
}
},
"id": 3774,
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"memberName": "add",
"nodeType": "MemberAccess",
"referencedDeclaration": 3448,
"src": "36152:12:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_struct$_Role_$3414_storage_ptr_$_t_address_$returns$__$bound_to$_t_struct$_Role_$3414_storage_ptr_$",
"typeString": "function (struct Roles.Role storage pointer,address)"
}
},
"id": 3776,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "36152:21:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3777,
"nodeType": "ExpressionStatement",
"src": "36152:21:13"
},
{
"eventCall": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3779,
"name": "account",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3769,
"src": "36200:7:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 3778,
"name": "PauserAdded",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3698,
"src": "36188:11:13",
"typeDescriptions": {
"typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$",
"typeString": "function (address)"
}
},
"id": 3780,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "36188:20:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3781,
"nodeType": "EmitStatement",
"src": "36183:25:13"
}
]
},
"documentation": null,
"id": 3783,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "_addPauser",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 3770,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3769,
"mutability": "mutable",
"name": "account",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3783,
"src": "36116:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3768,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "36116:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "36115:17:13"
},
"returnParameters": {
"id": 3771,
"nodeType": "ParameterList",
"parameters": [],
"src": "36142:0:13"
},
"scope": 3804,
"src": "36096:119:13",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 3798,
"nodeType": "Block",
"src": "36270:78:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3791,
"name": "account",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3785,
"src": "36296:7:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"expression": {
"argumentTypes": null,
"id": 3788,
"name": "_pausers",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3704,
"src": "36280:8:13",
"typeDescriptions": {
"typeIdentifier": "t_struct$_Role_$3414_storage",
"typeString": "struct Roles.Role storage ref"
}
},
"id": 3790,
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"memberName": "remove",
"nodeType": "MemberAccess",
"referencedDeclaration": 3481,
"src": "36280:15:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_struct$_Role_$3414_storage_ptr_$_t_address_$returns$__$bound_to$_t_struct$_Role_$3414_storage_ptr_$",
"typeString": "function (struct Roles.Role storage pointer,address)"
}
},
"id": 3792,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "36280:24:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3793,
"nodeType": "ExpressionStatement",
"src": "36280:24:13"
},
{
"eventCall": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3795,
"name": "account",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3785,
"src": "36333:7:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 3794,
"name": "PauserRemoved",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3702,
"src": "36319:13:13",
"typeDescriptions": {
"typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$",
"typeString": "function (address)"
}
},
"id": 3796,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "36319:22:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3797,
"nodeType": "EmitStatement",
"src": "36314:27:13"
}
]
},
"documentation": null,
"id": 3799,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "_removePauser",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 3786,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3785,
"mutability": "mutable",
"name": "account",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3799,
"src": "36244:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3784,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "36244:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "36243:17:13"
},
"returnParameters": {
"id": 3787,
"nodeType": "ParameterList",
"parameters": [],
"src": "36270:0:13"
},
"scope": 3804,
"src": "36221:127:13",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "internal"
},
{
"constant": false,
"id": 3803,
"mutability": "mutable",
"name": "______gap",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3804,
"src": "36354:29:13",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$50_storage",
"typeString": "uint256[50]"
},
"typeName": {
"baseType": {
"id": 3800,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "36354:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3802,
"length": {
"argumentTypes": null,
"hexValue": "3530",
"id": 3801,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "36362:2:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_50_by_1",
"typeString": "int_const 50"
},
"value": "50"
},
"nodeType": "ArrayTypeName",
"src": "36354:11:13",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$50_storage_ptr",
"typeString": "uint256[50]"
}
},
"value": null,
"visibility": "private"
}
],
"scope": 4171,
"src": "35359:1027:13"
},
{
"abstract": false,
"baseContracts": [
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 3806,
"name": "Initializable",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 74,
"src": "36567:13:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_Initializable_$74",
"typeString": "contract Initializable"
}
},
"id": 3807,
"nodeType": "InheritanceSpecifier",
"src": "36567:13:13"
},
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 3808,
"name": "PauserRole",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 3804,
"src": "36582:10:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_PauserRole_$3804",
"typeString": "contract PauserRole"
}
},
"id": 3809,
"nodeType": "InheritanceSpecifier",
"src": "36582:10:13"
}
],
"contractDependencies": [
74,
3804
],
"contractKind": "contract",
"documentation": {
"id": 3805,
"nodeType": "StructuredDocumentation",
"src": "36433:112:13",
"text": " @title Pausable\n @dev Base contract which allows children to implement an emergency stop mechanism."
},
"fullyImplemented": true,
"id": 3906,
"linearizedBaseContracts": [
3906,
3804,
74
],
"name": "Pausable",
"nodeType": "ContractDefinition",
"nodes": [
{
"anonymous": false,
"documentation": null,
"id": 3813,
"name": "Paused",
"nodeType": "EventDefinition",
"parameters": {
"id": 3812,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3811,
"indexed": false,
"mutability": "mutable",
"name": "account",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3813,
"src": "36612:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3810,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "36612:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "36611:17:13"
},
"src": "36599:30:13"
},
{
"anonymous": false,
"documentation": null,
"id": 3817,
"name": "Unpaused",
"nodeType": "EventDefinition",
"parameters": {
"id": 3816,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3815,
"indexed": false,
"mutability": "mutable",
"name": "account",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3817,
"src": "36649:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3814,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "36649:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "36648:17:13"
},
"src": "36634:32:13"
},
{
"constant": false,
"id": 3819,
"mutability": "mutable",
"name": "_paused",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3906,
"src": "36672:20:13",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 3818,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "36672:4:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "private"
},
{
"body": {
"id": 3836,
"nodeType": "Block",
"src": "36762:82:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3829,
"name": "sender",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3821,
"src": "36804:6:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"expression": {
"argumentTypes": null,
"id": 3826,
"name": "PauserRole",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3804,
"src": "36772:10:13",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_contract$_PauserRole_$3804_$",
"typeString": "type(contract PauserRole)"
}
},
"id": 3828,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "initializePauserRole",
"nodeType": "MemberAccess",
"referencedDeclaration": 3722,
"src": "36772:31:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$returns$__$",
"typeString": "function (address)"
}
},
"id": 3830,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "36772:39:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3831,
"nodeType": "ExpressionStatement",
"src": "36772:39:13"
},
{
"expression": {
"argumentTypes": null,
"id": 3834,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"id": 3832,
"name": "_paused",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3819,
"src": "36822:7:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"hexValue": "66616c7365",
"id": 3833,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "bool",
"lValueRequested": false,
"nodeType": "Literal",
"src": "36832:5:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"value": "false"
},
"src": "36822:15:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"id": 3835,
"nodeType": "ExpressionStatement",
"src": "36822:15:13"
}
]
},
"documentation": null,
"functionSelector": "b21f2d3b",
"id": 3837,
"implemented": true,
"kind": "function",
"modifiers": [
{
"arguments": null,
"id": 3824,
"modifierName": {
"argumentTypes": null,
"id": 3823,
"name": "initializer",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 47,
"src": "36750:11:13",
"typeDescriptions": {
"typeIdentifier": "t_modifier$__$",
"typeString": "modifier ()"
}
},
"nodeType": "ModifierInvocation",
"src": "36750:11:13"
}
],
"name": "initializePausable",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 3822,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3821,
"mutability": "mutable",
"name": "sender",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3837,
"src": "36727:14:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3820,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "36727:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "36726:16:13"
},
"returnParameters": {
"id": 3825,
"nodeType": "ParameterList",
"parameters": [],
"src": "36762:0:13"
},
"scope": 3906,
"src": "36699:145:13",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
{
"body": {
"id": 3845,
"nodeType": "Block",
"src": "36975:31:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"id": 3843,
"name": "_paused",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3819,
"src": "36992:7:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"functionReturnParameters": 3842,
"id": 3844,
"nodeType": "Return",
"src": "36985:14:13"
}
]
},
"documentation": {
"id": 3838,
"nodeType": "StructuredDocumentation",
"src": "36850:75:13",
"text": " @return true if the contract is paused, false otherwise."
},
"functionSelector": "5c975abb",
"id": 3846,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "paused",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 3839,
"nodeType": "ParameterList",
"parameters": [],
"src": "36945:2:13"
},
"returnParameters": {
"id": 3842,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3841,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3846,
"src": "36969:4:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 3840,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "36969:4:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "36968:6:13"
},
"scope": 3906,
"src": "36930:76:13",
"stateMutability": "view",
"virtual": false,
"visibility": "public"
},
{
"body": {
"id": 3855,
"nodeType": "Block",
"src": "37140:45:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3851,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"nodeType": "UnaryOperation",
"operator": "!",
"prefix": true,
"src": "37158:8:13",
"subExpression": {
"argumentTypes": null,
"id": 3850,
"name": "_paused",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3819,
"src": "37159:7:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 3849,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "37150:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 3852,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "37150:17:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3853,
"nodeType": "ExpressionStatement",
"src": "37150:17:13"
},
{
"id": 3854,
"nodeType": "PlaceholderStatement",
"src": "37177:1:13"
}
]
},
"documentation": {
"id": 3847,
"nodeType": "StructuredDocumentation",
"src": "37012:98:13",
"text": " @dev Modifier to make a function callable only when the contract is not paused."
},
"id": 3856,
"name": "whenNotPaused",
"nodeType": "ModifierDefinition",
"overrides": null,
"parameters": {
"id": 3848,
"nodeType": "ParameterList",
"parameters": [],
"src": "37137:2:13"
},
"src": "37115:70:13",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 3864,
"nodeType": "Block",
"src": "37312:44:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3860,
"name": "_paused",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3819,
"src": "37330:7:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 3859,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "37322:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 3861,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "37322:16:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3862,
"nodeType": "ExpressionStatement",
"src": "37322:16:13"
},
{
"id": 3863,
"nodeType": "PlaceholderStatement",
"src": "37348:1:13"
}
]
},
"documentation": {
"id": 3857,
"nodeType": "StructuredDocumentation",
"src": "37191:94:13",
"text": " @dev Modifier to make a function callable only when the contract is paused."
},
"id": 3865,
"name": "whenPaused",
"nodeType": "ModifierDefinition",
"overrides": null,
"parameters": {
"id": 3858,
"nodeType": "ParameterList",
"parameters": [],
"src": "37309:2:13"
},
"src": "37290:66:13",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 3882,
"nodeType": "Block",
"src": "37492:64:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"id": 3875,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"id": 3873,
"name": "_paused",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3819,
"src": "37502:7:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"hexValue": "74727565",
"id": 3874,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "bool",
"lValueRequested": false,
"nodeType": "Literal",
"src": "37512:4:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"value": "true"
},
"src": "37502:14:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"id": 3876,
"nodeType": "ExpressionStatement",
"src": "37502:14:13"
},
{
"eventCall": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 3878,
"name": "msg",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": -15,
"src": "37538:3:13",
"typeDescriptions": {
"typeIdentifier": "t_magic_message",
"typeString": "msg"
}
},
"id": 3879,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "sender",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "37538:10:13",
"typeDescriptions": {
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
}
],
"id": 3877,
"name": "Paused",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3813,
"src": "37531:6:13",
"typeDescriptions": {
"typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$",
"typeString": "function (address)"
}
},
"id": 3880,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "37531:18:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3881,
"nodeType": "EmitStatement",
"src": "37526:23:13"
}
]
},
"documentation": {
"id": 3866,
"nodeType": "StructuredDocumentation",
"src": "37362:76:13",
"text": " @dev called by the owner to pause, triggers stopped state"
},
"functionSelector": "8456cb59",
"id": 3883,
"implemented": true,
"kind": "function",
"modifiers": [
{
"arguments": null,
"id": 3869,
"modifierName": {
"argumentTypes": null,
"id": 3868,
"name": "onlyPauser",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3733,
"src": "37467:10:13",
"typeDescriptions": {
"typeIdentifier": "t_modifier$__$",
"typeString": "modifier ()"
}
},
"nodeType": "ModifierInvocation",
"src": "37467:10:13"
},
{
"arguments": null,
"id": 3871,
"modifierName": {
"argumentTypes": null,
"id": 3870,
"name": "whenNotPaused",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3856,
"src": "37478:13:13",
"typeDescriptions": {
"typeIdentifier": "t_modifier$__$",
"typeString": "modifier ()"
}
},
"nodeType": "ModifierInvocation",
"src": "37478:13:13"
}
],
"name": "pause",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 3867,
"nodeType": "ParameterList",
"parameters": [],
"src": "37457:2:13"
},
"returnParameters": {
"id": 3872,
"nodeType": "ParameterList",
"parameters": [],
"src": "37492:0:13"
},
"scope": 3906,
"src": "37443:113:13",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
{
"body": {
"id": 3900,
"nodeType": "Block",
"src": "37694:67:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"id": 3893,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"id": 3891,
"name": "_paused",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3819,
"src": "37704:7:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"hexValue": "66616c7365",
"id": 3892,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "bool",
"lValueRequested": false,
"nodeType": "Literal",
"src": "37714:5:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"value": "false"
},
"src": "37704:15:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"id": 3894,
"nodeType": "ExpressionStatement",
"src": "37704:15:13"
},
{
"eventCall": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 3896,
"name": "msg",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": -15,
"src": "37743:3:13",
"typeDescriptions": {
"typeIdentifier": "t_magic_message",
"typeString": "msg"
}
},
"id": 3897,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "sender",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "37743:10:13",
"typeDescriptions": {
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
}
],
"id": 3895,
"name": "Unpaused",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3817,
"src": "37734:8:13",
"typeDescriptions": {
"typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$",
"typeString": "function (address)"
}
},
"id": 3898,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "37734:20:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3899,
"nodeType": "EmitStatement",
"src": "37729:25:13"
}
]
},
"documentation": {
"id": 3884,
"nodeType": "StructuredDocumentation",
"src": "37562:79:13",
"text": " @dev called by the owner to unpause, returns to normal state"
},
"functionSelector": "3f4ba83a",
"id": 3901,
"implemented": true,
"kind": "function",
"modifiers": [
{
"arguments": null,
"id": 3887,
"modifierName": {
"argumentTypes": null,
"id": 3886,
"name": "onlyPauser",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3733,
"src": "37672:10:13",
"typeDescriptions": {
"typeIdentifier": "t_modifier$__$",
"typeString": "modifier ()"
}
},
"nodeType": "ModifierInvocation",
"src": "37672:10:13"
},
{
"arguments": null,
"id": 3889,
"modifierName": {
"argumentTypes": null,
"id": 3888,
"name": "whenPaused",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3865,
"src": "37683:10:13",
"typeDescriptions": {
"typeIdentifier": "t_modifier$__$",
"typeString": "modifier ()"
}
},
"nodeType": "ModifierInvocation",
"src": "37683:10:13"
}
],
"name": "unpause",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 3885,
"nodeType": "ParameterList",
"parameters": [],
"src": "37662:2:13"
},
"returnParameters": {
"id": 3890,
"nodeType": "ParameterList",
"parameters": [],
"src": "37694:0:13"
},
"scope": 3906,
"src": "37646:115:13",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
{
"constant": false,
"id": 3905,
"mutability": "mutable",
"name": "______gap",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3906,
"src": "37767:29:13",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$50_storage",
"typeString": "uint256[50]"
},
"typeName": {
"baseType": {
"id": 3902,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "37767:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3904,
"length": {
"argumentTypes": null,
"hexValue": "3530",
"id": 3903,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "37775:2:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_50_by_1",
"typeString": "int_const 50"
},
"value": "50"
},
"nodeType": "ArrayTypeName",
"src": "37767:11:13",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$50_storage_ptr",
"typeString": "uint256[50]"
}
},
"value": null,
"visibility": "private"
}
],
"scope": 4171,
"src": "36546:1253:13"
},
{
"abstract": false,
"baseContracts": [
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 3908,
"name": "Initializable",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 74,
"src": "38006:13:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_Initializable_$74",
"typeString": "contract Initializable"
}
},
"id": 3909,
"nodeType": "InheritanceSpecifier",
"src": "38006:13:13"
},
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 3910,
"name": "MockERC721",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 2838,
"src": "38021:10:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_MockERC721_$2838",
"typeString": "contract MockERC721"
}
},
"id": 3911,
"nodeType": "InheritanceSpecifier",
"src": "38021:10:13"
},
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 3912,
"name": "Pausable",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 3906,
"src": "38033:8:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_Pausable_$3906",
"typeString": "contract Pausable"
}
},
"id": 3913,
"nodeType": "InheritanceSpecifier",
"src": "38033:8:13"
}
],
"contractDependencies": [
74,
1976,
2006,
2235,
2838,
3804,
3906
],
"contractKind": "contract",
"documentation": {
"id": 3907,
"nodeType": "StructuredDocumentation",
"src": "37864:110:13",
"text": " @title MockERC721 Non-Fungible Pausable token\n @dev MockERC721 modified with pausable transfers.*"
},
"fullyImplemented": true,
"id": 3992,
"linearizedBaseContracts": [
3992,
3906,
3804,
2838,
2006,
2235,
1976,
74
],
"name": "MockERC721Pausable",
"nodeType": "ContractDefinition",
"nodes": [
{
"body": {
"id": 3932,
"nodeType": "Block",
"src": "38103:113:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [],
"expression": {
"argumentTypes": [],
"expression": {
"argumentTypes": null,
"id": 3921,
"name": "MockERC721",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2838,
"src": "38121:10:13",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_contract$_MockERC721_$2838_$",
"typeString": "type(contract MockERC721)"
}
},
"id": 3922,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "_hasBeenInitializedMockERC721",
"nodeType": "MemberAccess",
"referencedDeclaration": 2297,
"src": "38121:40:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$__$returns$_t_bool_$",
"typeString": "function () view returns (bool)"
}
},
"id": 3923,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "38121:42:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"id": 3920,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "38113:7:13",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
"typeString": "function (bool) pure"
}
},
"id": 3924,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "38113:51:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3925,
"nodeType": "ExpressionStatement",
"src": "38113:51:13"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3929,
"name": "sender",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3915,
"src": "38202:6:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"expression": {
"argumentTypes": null,
"id": 3926,
"name": "Pausable",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3906,
"src": "38174:8:13",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_contract$_Pausable_$3906_$",
"typeString": "type(contract Pausable)"
}
},
"id": 3928,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "initializePausable",
"nodeType": "MemberAccess",
"referencedDeclaration": 3837,
"src": "38174:27:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$returns$__$",
"typeString": "function (address)"
}
},
"id": 3930,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "38174:35:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3931,
"nodeType": "ExpressionStatement",
"src": "38174:35:13"
}
]
},
"documentation": null,
"functionSelector": "c4d66de8",
"id": 3933,
"implemented": true,
"kind": "function",
"modifiers": [
{
"arguments": null,
"id": 3918,
"modifierName": {
"argumentTypes": null,
"id": 3917,
"name": "initializer",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 47,
"src": "38091:11:13",
"typeDescriptions": {
"typeIdentifier": "t_modifier$__$",
"typeString": "modifier ()"
}
},
"nodeType": "ModifierInvocation",
"src": "38091:11:13"
}
],
"name": "initialize",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 3916,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3915,
"mutability": "mutable",
"name": "sender",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3933,
"src": "38068:14:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3914,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "38068:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "38067:16:13"
},
"returnParameters": {
"id": 3919,
"nodeType": "ParameterList",
"parameters": [],
"src": "38103:0:13"
},
"scope": 3992,
"src": "38048:168:13",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
{
"body": {
"id": 3949,
"nodeType": "Block",
"src": "38289:53:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3945,
"name": "to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3935,
"src": "38323:2:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 3946,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3937,
"src": "38327:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"expression": {
"argumentTypes": null,
"id": 3942,
"name": "super",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": -25,
"src": "38299:5:13",
"typeDescriptions": {
"typeIdentifier": "t_super$_MockERC721Pausable_$3992",
"typeString": "contract super MockERC721Pausable"
}
},
"id": 3944,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "approveMockERC721",
"nodeType": "MemberAccess",
"referencedDeclaration": 2391,
"src": "38299:23:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_uint256_$returns$__$",
"typeString": "function (address,uint256)"
}
},
"id": 3947,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "38299:36:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3948,
"nodeType": "ExpressionStatement",
"src": "38299:36:13"
}
]
},
"documentation": null,
"functionSelector": "095ea7b3",
"id": 3950,
"implemented": true,
"kind": "function",
"modifiers": [
{
"arguments": null,
"id": 3940,
"modifierName": {
"argumentTypes": null,
"id": 3939,
"name": "whenNotPaused",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3856,
"src": "38275:13:13",
"typeDescriptions": {
"typeIdentifier": "t_modifier$__$",
"typeString": "modifier ()"
}
},
"nodeType": "ModifierInvocation",
"src": "38275:13:13"
}
],
"name": "approve",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 3938,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3935,
"mutability": "mutable",
"name": "to",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3950,
"src": "38239:10:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3934,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "38239:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 3937,
"mutability": "mutable",
"name": "tokenId",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3950,
"src": "38251:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 3936,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "38251:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "38238:29:13"
},
"returnParameters": {
"id": 3941,
"nodeType": "ParameterList",
"parameters": [],
"src": "38289:0:13"
},
"scope": 3992,
"src": "38222:120:13",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
{
"body": {
"id": 3966,
"nodeType": "Block",
"src": "38424:64:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3962,
"name": "to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3952,
"src": "38468:2:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 3963,
"name": "approved",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3954,
"src": "38472:8:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_bool",
"typeString": "bool"
}
],
"expression": {
"argumentTypes": null,
"id": 3959,
"name": "super",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": -25,
"src": "38434:5:13",
"typeDescriptions": {
"typeIdentifier": "t_super$_MockERC721Pausable_$3992",
"typeString": "contract super MockERC721Pausable"
}
},
"id": 3961,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "setApprovalForAllMockERC721",
"nodeType": "MemberAccess",
"referencedDeclaration": 2442,
"src": "38434:33:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_bool_$returns$__$",
"typeString": "function (address,bool)"
}
},
"id": 3964,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "38434:47:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3965,
"nodeType": "ExpressionStatement",
"src": "38434:47:13"
}
]
},
"documentation": null,
"functionSelector": "a22cb465",
"id": 3967,
"implemented": true,
"kind": "function",
"modifiers": [
{
"arguments": null,
"id": 3957,
"modifierName": {
"argumentTypes": null,
"id": 3956,
"name": "whenNotPaused",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3856,
"src": "38409:13:13",
"typeDescriptions": {
"typeIdentifier": "t_modifier$__$",
"typeString": "modifier ()"
}
},
"nodeType": "ModifierInvocation",
"src": "38409:13:13"
}
],
"name": "setApprovalForAll",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 3955,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3952,
"mutability": "mutable",
"name": "to",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3967,
"src": "38375:10:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3951,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "38375:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 3954,
"mutability": "mutable",
"name": "approved",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3967,
"src": "38387:13:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 3953,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "38387:4:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "38374:27:13"
},
"returnParameters": {
"id": 3958,
"nodeType": "ParameterList",
"parameters": [],
"src": "38424:0:13"
},
"scope": 3992,
"src": "38348:140:13",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
{
"body": {
"id": 3986,
"nodeType": "Block",
"src": "38581:64:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 3981,
"name": "from",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3969,
"src": "38620:4:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 3982,
"name": "to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3971,
"src": "38626:2:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 3983,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3973,
"src": "38630:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"expression": {
"argumentTypes": null,
"id": 3978,
"name": "super",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": -25,
"src": "38591:5:13",
"typeDescriptions": {
"typeIdentifier": "t_super$_MockERC721Pausable_$3992",
"typeString": "contract super MockERC721Pausable"
}
},
"id": 3980,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "transferFromMockERC721",
"nodeType": "MemberAccess",
"referencedDeclaration": 2484,
"src": "38591:28:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$",
"typeString": "function (address,address,uint256)"
}
},
"id": 3984,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "38591:47:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 3985,
"nodeType": "ExpressionStatement",
"src": "38591:47:13"
}
]
},
"documentation": null,
"functionSelector": "23b872dd",
"id": 3987,
"implemented": true,
"kind": "function",
"modifiers": [
{
"arguments": null,
"id": 3976,
"modifierName": {
"argumentTypes": null,
"id": 3975,
"name": "whenNotPaused",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3856,
"src": "38566:13:13",
"typeDescriptions": {
"typeIdentifier": "t_modifier$__$",
"typeString": "modifier ()"
}
},
"nodeType": "ModifierInvocation",
"src": "38566:13:13"
}
],
"name": "transferFrom",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 3974,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 3969,
"mutability": "mutable",
"name": "from",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3987,
"src": "38516:12:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3968,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "38516:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 3971,
"mutability": "mutable",
"name": "to",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3987,
"src": "38530:10:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 3970,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "38530:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 3973,
"mutability": "mutable",
"name": "tokenId",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3987,
"src": "38542:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 3972,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "38542:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "38515:43:13"
},
"returnParameters": {
"id": 3977,
"nodeType": "ParameterList",
"parameters": [],
"src": "38581:0:13"
},
"scope": 3992,
"src": "38494:151:13",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
{
"constant": false,
"id": 3991,
"mutability": "mutable",
"name": "______gap",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 3992,
"src": "38651:29:13",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$50_storage",
"typeString": "uint256[50]"
},
"typeName": {
"baseType": {
"id": 3988,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "38651:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 3990,
"length": {
"argumentTypes": null,
"hexValue": "3530",
"id": 3989,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "38659:2:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_50_by_1",
"typeString": "int_const 50"
},
"value": "50"
},
"nodeType": "ArrayTypeName",
"src": "38651:11:13",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$50_storage_ptr",
"typeString": "uint256[50]"
}
},
"value": null,
"visibility": "private"
}
],
"scope": 4171,
"src": "37975:708:13"
},
{
"abstract": false,
"baseContracts": [
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 3994,
"name": "Initializable",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 74,
"src": "38877:13:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_Initializable_$74",
"typeString": "contract Initializable"
}
},
"id": 3995,
"nodeType": "InheritanceSpecifier",
"src": "38877:13:13"
},
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 3996,
"name": "MockERC721",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 2838,
"src": "38892:10:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_MockERC721_$2838",
"typeString": "contract MockERC721"
}
},
"id": 3997,
"nodeType": "InheritanceSpecifier",
"src": "38892:10:13"
},
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 3998,
"name": "MockERC721Enumerable",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 3229,
"src": "38904:20:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_MockERC721Enumerable_$3229",
"typeString": "contract MockERC721Enumerable"
}
},
"id": 3999,
"nodeType": "InheritanceSpecifier",
"src": "38904:20:13"
},
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 4000,
"name": "MockERC721Metadata",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 3408,
"src": "38926:18:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_MockERC721Metadata_$3408",
"typeString": "contract MockERC721Metadata"
}
},
"id": 4001,
"nodeType": "InheritanceSpecifier",
"src": "38926:18:13"
},
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 4002,
"name": "MockERC721MetadataMintable",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 3689,
"src": "38946:26:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_MockERC721MetadataMintable_$3689",
"typeString": "contract MockERC721MetadataMintable"
}
},
"id": 4003,
"nodeType": "InheritanceSpecifier",
"src": "38946:26:13"
},
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 4004,
"name": "MockERC721Pausable",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 3992,
"src": "38974:18:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_MockERC721Pausable_$3992",
"typeString": "contract MockERC721Pausable"
}
},
"id": 4005,
"nodeType": "InheritanceSpecifier",
"src": "38974:18:13"
}
],
"contractDependencies": [
74,
1976,
2006,
2235,
2838,
2865,
3229,
3252,
3408,
3622,
3689,
3804,
3906,
3992
],
"contractKind": "contract",
"documentation": {
"id": 3993,
"nodeType": "StructuredDocumentation",
"src": "38754:85:13",
"text": " @title Standard MockERC721 token, with minting and pause functionality."
},
"fullyImplemented": true,
"id": 4170,
"linearizedBaseContracts": [
4170,
3992,
3906,
3804,
3689,
3622,
3408,
3252,
3229,
2865,
2838,
2006,
2235,
1976,
74
],
"name": "MockStandaloneERC721",
"nodeType": "ContractDefinition",
"nodes": [
{
"body": {
"id": 4107,
"nodeType": "Block",
"src": "39132:780:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [],
"expression": {
"argumentTypes": [],
"expression": {
"argumentTypes": null,
"id": 4020,
"name": "MockERC721",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 2838,
"src": "39142:10:13",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_contract$_MockERC721_$2838_$",
"typeString": "type(contract MockERC721)"
}
},
"id": 4022,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "initialize",
"nodeType": "MemberAccess",
"referencedDeclaration": 2287,
"src": "39142:21:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$__$returns$__$",
"typeString": "function ()"
}
},
"id": 4023,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "39142:23:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 4024,
"nodeType": "ExpressionStatement",
"src": "39142:23:13"
},
{
"expression": {
"argumentTypes": null,
"arguments": [],
"expression": {
"argumentTypes": [],
"expression": {
"argumentTypes": null,
"id": 4025,
"name": "MockERC721Enumerable",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3229,
"src": "39175:20:13",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_contract$_MockERC721Enumerable_$3229_$",
"typeString": "type(contract MockERC721Enumerable)"
}
},
"id": 4027,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "initializeMockERC721Enumerable",
"nodeType": "MemberAccess",
"referencedDeclaration": 2910,
"src": "39175:51:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$__$returns$__$",
"typeString": "function ()"
}
},
"id": 4028,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "39175:53:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 4029,
"nodeType": "ExpressionStatement",
"src": "39175:53:13"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 4033,
"name": "name",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 4007,
"src": "39268:4:13",
"typeDescriptions": {
"typeIdentifier": "t_string_memory_ptr",
"typeString": "string memory"
}
},
{
"argumentTypes": null,
"id": 4034,
"name": "symbol",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 4009,
"src": "39274:6:13",
"typeDescriptions": {
"typeIdentifier": "t_string_memory_ptr",
"typeString": "string memory"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_string_memory_ptr",
"typeString": "string memory"
},
{
"typeIdentifier": "t_string_memory_ptr",
"typeString": "string memory"
}
],
"expression": {
"argumentTypes": null,
"id": 4030,
"name": "MockERC721Metadata",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3408,
"src": "39238:18:13",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_contract$_MockERC721Metadata_$3408_$",
"typeString": "type(contract MockERC721Metadata)"
}
},
"id": 4032,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "initialize",
"nodeType": "MemberAccess",
"referencedDeclaration": 3300,
"src": "39238:29:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_string_memory_ptr_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (string memory,string memory)"
}
},
"id": 4035,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "39238:43:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 4036,
"nodeType": "ExpressionStatement",
"src": "39238:43:13"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 4042,
"name": "this",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": -28,
"src": "39433:4:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_MockStandaloneERC721_$4170",
"typeString": "contract MockStandaloneERC721"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_contract$_MockStandaloneERC721_$4170",
"typeString": "contract MockStandaloneERC721"
}
],
"id": 4041,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "ElementaryTypeNameExpression",
"src": "39425:7:13",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_address_$",
"typeString": "type(address)"
},
"typeName": {
"id": 4040,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "39425:7:13",
"typeDescriptions": {
"typeIdentifier": null,
"typeString": null
}
}
},
"id": 4043,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "39425:13:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"expression": {
"argumentTypes": null,
"id": 4037,
"name": "MockERC721MetadataMintable",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3689,
"src": "39361:26:13",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_contract$_MockERC721MetadataMintable_$3689_$",
"typeString": "type(contract MockERC721MetadataMintable)"
}
},
"id": 4039,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "initializeMockERC721MetadataMintable",
"nodeType": "MemberAccess",
"referencedDeclaration": 3657,
"src": "39361:63:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$returns$__$",
"typeString": "function (address)"
}
},
"id": 4044,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "39361:78:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 4045,
"nodeType": "ExpressionStatement",
"src": "39361:78:13"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 4049,
"name": "this",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": -28,
"src": "39471:4:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_MockStandaloneERC721_$4170",
"typeString": "contract MockStandaloneERC721"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_contract$_MockStandaloneERC721_$4170",
"typeString": "contract MockStandaloneERC721"
}
],
"id": 4048,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "ElementaryTypeNameExpression",
"src": "39463:7:13",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_address_$",
"typeString": "type(address)"
},
"typeName": {
"id": 4047,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "39463:7:13",
"typeDescriptions": {
"typeIdentifier": null,
"typeString": null
}
}
},
"id": 4050,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "39463:13:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 4046,
"name": "_removeMinter",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3617,
"src": "39449:13:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$returns$__$",
"typeString": "function (address)"
}
},
"id": 4051,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "39449:28:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 4052,
"nodeType": "ExpressionStatement",
"src": "39449:28:13"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 4058,
"name": "this",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": -28,
"src": "39526:4:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_MockStandaloneERC721_$4170",
"typeString": "contract MockStandaloneERC721"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_contract$_MockStandaloneERC721_$4170",
"typeString": "contract MockStandaloneERC721"
}
],
"id": 4057,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "ElementaryTypeNameExpression",
"src": "39518:7:13",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_address_$",
"typeString": "type(address)"
},
"typeName": {
"id": 4056,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "39518:7:13",
"typeDescriptions": {
"typeIdentifier": null,
"typeString": null
}
}
},
"id": 4059,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "39518:13:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"expression": {
"argumentTypes": null,
"id": 4053,
"name": "MockERC721Pausable",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3992,
"src": "39488:18:13",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_contract$_MockERC721Pausable_$3992_$",
"typeString": "type(contract MockERC721Pausable)"
}
},
"id": 4055,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "initialize",
"nodeType": "MemberAccess",
"referencedDeclaration": 3933,
"src": "39488:29:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$returns$__$",
"typeString": "function (address)"
}
},
"id": 4060,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "39488:44:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 4061,
"nodeType": "ExpressionStatement",
"src": "39488:44:13"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 4065,
"name": "this",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": -28,
"src": "39564:4:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_MockStandaloneERC721_$4170",
"typeString": "contract MockStandaloneERC721"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_contract$_MockStandaloneERC721_$4170",
"typeString": "contract MockStandaloneERC721"
}
],
"id": 4064,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "ElementaryTypeNameExpression",
"src": "39556:7:13",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_address_$",
"typeString": "type(address)"
},
"typeName": {
"id": 4063,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "39556:7:13",
"typeDescriptions": {
"typeIdentifier": null,
"typeString": null
}
}
},
"id": 4066,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "39556:13:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 4062,
"name": "_removePauser",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3799,
"src": "39542:13:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$returns$__$",
"typeString": "function (address)"
}
},
"id": 4067,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "39542:28:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 4068,
"nodeType": "ExpressionStatement",
"src": "39542:28:13"
},
{
"body": {
"id": 4086,
"nodeType": "Block",
"src": "39757:47:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 4081,
"name": "minters",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 4012,
"src": "39782:7:13",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
"typeString": "address[] memory"
}
},
"id": 4083,
"indexExpression": {
"argumentTypes": null,
"id": 4082,
"name": "i",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 4070,
"src": "39790:1:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "39782:10:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 4080,
"name": "_addMinter",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3601,
"src": "39771:10:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$returns$__$",
"typeString": "function (address)"
}
},
"id": 4084,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "39771:22:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 4085,
"nodeType": "ExpressionStatement",
"src": "39771:22:13"
}
]
},
"condition": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 4076,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 4073,
"name": "i",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 4070,
"src": "39732:1:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "<",
"rightExpression": {
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 4074,
"name": "minters",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 4012,
"src": "39736:7:13",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
"typeString": "address[] memory"
}
},
"id": 4075,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "length",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "39736:14:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "39732:18:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"id": 4087,
"initializationExpression": {
"assignments": [
4070
],
"declarations": [
{
"constant": false,
"id": 4070,
"mutability": "mutable",
"name": "i",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 4087,
"src": "39717:9:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 4069,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "39717:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 4072,
"initialValue": {
"argumentTypes": null,
"hexValue": "30",
"id": 4071,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "39729:1:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
},
"nodeType": "VariableDeclarationStatement",
"src": "39717:13:13"
},
"loopExpression": {
"expression": {
"argumentTypes": null,
"id": 4078,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"nodeType": "UnaryOperation",
"operator": "++",
"prefix": true,
"src": "39752:3:13",
"subExpression": {
"argumentTypes": null,
"id": 4077,
"name": "i",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 4070,
"src": "39754:1:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 4079,
"nodeType": "ExpressionStatement",
"src": "39752:3:13"
},
"nodeType": "ForStatement",
"src": "39712:92:13"
},
{
"body": {
"id": 4105,
"nodeType": "Block",
"src": "39859:47:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 4100,
"name": "pausers",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 4015,
"src": "39884:7:13",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
"typeString": "address[] memory"
}
},
"id": 4102,
"indexExpression": {
"argumentTypes": null,
"id": 4101,
"name": "i",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 4089,
"src": "39892:1:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "39884:10:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 4099,
"name": "_addPauser",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3783,
"src": "39873:10:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$returns$__$",
"typeString": "function (address)"
}
},
"id": 4103,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "39873:22:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 4104,
"nodeType": "ExpressionStatement",
"src": "39873:22:13"
}
]
},
"condition": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 4095,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 4092,
"name": "i",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 4089,
"src": "39834:1:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "<",
"rightExpression": {
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 4093,
"name": "pausers",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 4015,
"src": "39838:7:13",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
"typeString": "address[] memory"
}
},
"id": 4094,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "length",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "39838:14:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "39834:18:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"id": 4106,
"initializationExpression": {
"assignments": [
4089
],
"declarations": [
{
"constant": false,
"id": 4089,
"mutability": "mutable",
"name": "i",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 4106,
"src": "39819:9:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 4088,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "39819:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 4091,
"initialValue": {
"argumentTypes": null,
"hexValue": "30",
"id": 4090,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "39831:1:13",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
},
"nodeType": "VariableDeclarationStatement",
"src": "39819:13:13"
},
"loopExpression": {
"expression": {
"argumentTypes": null,
"id": 4097,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"nodeType": "UnaryOperation",
"operator": "++",
"prefix": true,
"src": "39854:3:13",
"subExpression": {
"argumentTypes": null,
"id": 4096,
"name": "i",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 4089,
"src": "39856:1:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 4098,
"nodeType": "ExpressionStatement",
"src": "39854:3:13"
},
"nodeType": "ForStatement",
"src": "39814:92:13"
}
]
},
"documentation": null,
"functionSelector": "d94cc0e0",
"id": 4108,
"implemented": true,
"kind": "function",
"modifiers": [
{
"arguments": null,
"id": 4018,
"modifierName": {
"argumentTypes": null,
"id": 4017,
"name": "initializer",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 47,
"src": "39120:11:13",
"typeDescriptions": {
"typeIdentifier": "t_modifier$__$",
"typeString": "modifier ()"
}
},
"nodeType": "ModifierInvocation",
"src": "39120:11:13"
}
],
"name": "initialize",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 4016,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 4007,
"mutability": "mutable",
"name": "name",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 4108,
"src": "39019:18:13",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_string_memory_ptr",
"typeString": "string"
},
"typeName": {
"id": 4006,
"name": "string",
"nodeType": "ElementaryTypeName",
"src": "39019:6:13",
"typeDescriptions": {
"typeIdentifier": "t_string_storage_ptr",
"typeString": "string"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 4009,
"mutability": "mutable",
"name": "symbol",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 4108,
"src": "39039:20:13",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_string_memory_ptr",
"typeString": "string"
},
"typeName": {
"id": 4008,
"name": "string",
"nodeType": "ElementaryTypeName",
"src": "39039:6:13",
"typeDescriptions": {
"typeIdentifier": "t_string_storage_ptr",
"typeString": "string"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 4012,
"mutability": "mutable",
"name": "minters",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 4108,
"src": "39061:24:13",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
"typeString": "address[]"
},
"typeName": {
"baseType": {
"id": 4010,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "39061:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"id": 4011,
"length": null,
"nodeType": "ArrayTypeName",
"src": "39061:9:13",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
"typeString": "address[]"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 4015,
"mutability": "mutable",
"name": "pausers",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 4108,
"src": "39087:24:13",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
"typeString": "address[]"
},
"typeName": {
"baseType": {
"id": 4013,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "39087:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"id": 4014,
"length": null,
"nodeType": "ArrayTypeName",
"src": "39087:9:13",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
"typeString": "address[]"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "39018:94:13"
},
"returnParameters": {
"id": 4019,
"nodeType": "ParameterList",
"parameters": [],
"src": "39132:0:13"
},
"scope": 4170,
"src": "38999:913:13",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
{
"baseFunctions": [
3063,
3403
],
"body": {
"id": 4132,
"nodeType": "Block",
"src": "40746:108:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 4121,
"name": "owner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 4110,
"src": "40782:5:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 4122,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 4112,
"src": "40789:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"expression": {
"argumentTypes": null,
"id": 4118,
"name": "MockERC721Enumerable",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3229,
"src": "40755:20:13",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_contract$_MockERC721Enumerable_$3229_$",
"typeString": "type(contract MockERC721Enumerable)"
}
},
"id": 4120,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "_burn",
"nodeType": "MemberAccess",
"referencedDeclaration": 3063,
"src": "40755:26:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_uint256_$returns$__$",
"typeString": "function (address,uint256)"
}
},
"id": 4123,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "40755:42:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 4124,
"nodeType": "ExpressionStatement",
"src": "40755:42:13"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 4128,
"name": "owner",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 4110,
"src": "40831:5:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 4129,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 4112,
"src": "40838:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"expression": {
"argumentTypes": null,
"id": 4125,
"name": "MockERC721Metadata",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3408,
"src": "40806:18:13",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_contract$_MockERC721Metadata_$3408_$",
"typeString": "type(contract MockERC721Metadata)"
}
},
"id": 4127,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "_burn",
"nodeType": "MemberAccess",
"referencedDeclaration": 3403,
"src": "40806:24:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_uint256_$returns$__$",
"typeString": "function (address,uint256)"
}
},
"id": 4130,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "40806:40:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 4131,
"nodeType": "ExpressionStatement",
"src": "40806:40:13"
}
]
},
"documentation": null,
"id": 4133,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "_burn",
"nodeType": "FunctionDefinition",
"overrides": {
"id": 4116,
"nodeType": "OverrideSpecifier",
"overrides": [
{
"contractScope": null,
"id": 4114,
"name": "MockERC721Enumerable",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 3229,
"src": "40705:20:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_MockERC721Enumerable_$3229",
"typeString": "contract MockERC721Enumerable"
}
},
{
"contractScope": null,
"id": 4115,
"name": "MockERC721Metadata",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 3408,
"src": "40726:18:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_MockERC721Metadata_$3408",
"typeString": "contract MockERC721Metadata"
}
}
],
"src": "40696:49:13"
},
"parameters": {
"id": 4113,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 4110,
"mutability": "mutable",
"name": "owner",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 4133,
"src": "40655:13:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 4109,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "40655:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 4112,
"mutability": "mutable",
"name": "tokenId",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 4133,
"src": "40670:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 4111,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "40670:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "40654:32:13"
},
"returnParameters": {
"id": 4117,
"nodeType": "ParameterList",
"parameters": [],
"src": "40746:0:13"
},
"scope": 4170,
"src": "40640:214:13",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "internal"
},
{
"baseFunctions": [
2920,
3310
],
"body": {
"id": 4151,
"nodeType": "Block",
"src": "40970:106:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [],
"expression": {
"argumentTypes": [],
"expression": {
"argumentTypes": null,
"id": 4141,
"name": "MockERC721Enumerable",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3229,
"src": "40978:20:13",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_contract$_MockERC721Enumerable_$3229_$",
"typeString": "type(contract MockERC721Enumerable)"
}
},
"id": 4143,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "_hasBeenInitialized",
"nodeType": "MemberAccess",
"referencedDeclaration": 2920,
"src": "40978:40:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$__$returns$_t_bool_$",
"typeString": "function () view returns (bool)"
}
},
"id": 4144,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "40978:42:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"id": 4145,
"nodeType": "ExpressionStatement",
"src": "40978:42:13"
},
{
"expression": {
"argumentTypes": null,
"arguments": [],
"expression": {
"argumentTypes": [],
"expression": {
"argumentTypes": null,
"id": 4146,
"name": "MockERC721Metadata",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3408,
"src": "41028:18:13",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_contract$_MockERC721Metadata_$3408_$",
"typeString": "type(contract MockERC721Metadata)"
}
},
"id": 4148,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "_hasBeenInitialized",
"nodeType": "MemberAccess",
"referencedDeclaration": 3310,
"src": "41028:38:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$__$returns$_t_bool_$",
"typeString": "function () view returns (bool)"
}
},
"id": 4149,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "41028:40:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"id": 4150,
"nodeType": "ExpressionStatement",
"src": "41028:40:13"
}
]
},
"documentation": null,
"id": 4152,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "_hasBeenInitialized",
"nodeType": "FunctionDefinition",
"overrides": {
"id": 4137,
"nodeType": "OverrideSpecifier",
"overrides": [
{
"contractScope": null,
"id": 4135,
"name": "MockERC721Enumerable",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 3229,
"src": "40913:20:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_MockERC721Enumerable_$3229",
"typeString": "contract MockERC721Enumerable"
}
},
{
"contractScope": null,
"id": 4136,
"name": "MockERC721Metadata",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 3408,
"src": "40935:18:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_MockERC721Metadata_$3408",
"typeString": "contract MockERC721Metadata"
}
}
],
"src": "40904:50:13"
},
"parameters": {
"id": 4134,
"nodeType": "ParameterList",
"parameters": [],
"src": "40887:2:13"
},
"returnParameters": {
"id": 4140,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 4139,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 4152,
"src": "40964:4:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 4138,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "40964:4:13",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "40963:6:13"
},
"scope": 4170,
"src": "40859:217:13",
"stateMutability": "view",
"virtual": false,
"visibility": "internal"
},
{
"baseFunctions": [
3032
],
"body": {
"id": 4168,
"nodeType": "Block",
"src": "41166:53:13",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 4164,
"name": "to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 4154,
"src": "41201:2:13",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 4165,
"name": "tokenId",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 4156,
"src": "41204:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"expression": {
"argumentTypes": null,
"id": 4161,
"name": "MockERC721Enumerable",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 3229,
"src": "41174:20:13",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_contract$_MockERC721Enumerable_$3229_$",
"typeString": "type(contract MockERC721Enumerable)"
}
},
"id": 4163,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "_mint",
"nodeType": "MemberAccess",
"referencedDeclaration": 3032,
"src": "41174:26:13",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_uint256_$returns$__$",
"typeString": "function (address,uint256)"
}
},
"id": 4166,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "41174:38:13",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 4167,
"nodeType": "ExpressionStatement",
"src": "41174:38:13"
}
]
},
"documentation": null,
"id": 4169,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "_mint",
"nodeType": "FunctionDefinition",
"overrides": {
"id": 4159,
"nodeType": "OverrideSpecifier",
"overrides": [
{
"contractScope": null,
"id": 4158,
"name": "MockERC721Enumerable",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 3229,
"src": "41144:20:13",
"typeDescriptions": {
"typeIdentifier": "t_contract$_MockERC721Enumerable_$3229",
"typeString": "contract MockERC721Enumerable"
}
}
],
"src": "41135:30:13"
},
"parameters": {
"id": 4157,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 4154,
"mutability": "mutable",
"name": "to",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 4169,
"src": "41097:10:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 4153,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "41097:7:13",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 4156,
"mutability": "mutable",
"name": "tokenId",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 4169,
"src": "41109:15:13",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 4155,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "41109:7:13",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "41096:29:13"
},
"returnParameters": {
"id": 4160,
"nodeType": "ParameterList",
"parameters": [],
"src": "41166:0:13"
},
"scope": 4170,
"src": "41082:137:13",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "internal"
}
],
"scope": 4171,
"src": "38840:2381:13"
}
],
"src": "0:41222:13"
},
"bytecode": "0x",
"deployedBytecode": "0x",
"compiler": {
"name": "solc",
"version": "0.6.10+commit.00c0fcaf.Emscripten.clang",
"optimizer": {},
"evmVersion": "constantinople"
}
}