{ "contractName": "Auctions", "abi": [ { "constant": true, "inputs": [ { "name": "", "type": "uint256" } ], "name": "auctions", "outputs": [ { "name": "name", "type": "string" }, { "name": "price", "type": "uint256" }, { "name": "metadata", "type": "string" }, { "name": "tokenId", "type": "uint256" }, { "name": "repoAddress", "type": "address" }, { "name": "owner", "type": "address" }, { "name": "active", "type": "bool" }, { "name": "finalized", "type": "bool" } ], "payable": false, "stateMutability": "view", "type": "function" }, { "constant": true, "inputs": [ { "name": "", "type": "address" }, { "name": "", "type": "uint256" } ], "name": "auctionOwner", "outputs": [ { "name": "", "type": "uint256" } ], "payable": false, "stateMutability": "view", "type": "function" }, { "payable": false, "stateMutability": "nonpayable", "type": "fallback" }, { "anonymous": false, "inputs": [ { "indexed": false, "name": "_owner", "type": "address" }, { "indexed": false, "name": "_auctionId", "type": "uint256" } ], "name": "AuctionCreated", "type": "event" }, { "anonymous": false, "inputs": [ { "indexed": false, "name": "_owner", "type": "address" }, { "indexed": false, "name": "_auctionId", "type": "uint256" } ], "name": "AuctionFinalized", "type": "event" }, { "constant": false, "inputs": [ { "name": "_repoAddress", "type": "address" }, { "name": "_tokenId", "type": "uint256" }, { "name": "_auctionTitle", "type": "string" }, { "name": "_metadata", "type": "string" }, { "name": "_price", "type": "uint256" } ], "name": "createAuction", "outputs": [ { "name": "", "type": "bool" } ], "payable": false, "stateMutability": "nonpayable", "type": "function" }, { "constant": false, "inputs": [ { "name": "_auctionId", "type": "uint256" }, { "name": "_to", "type": "address" } ], "name": "finalizeAuction", "outputs": [], "payable": false, "stateMutability": "nonpayable", "type": "function" }, { "constant": true, "inputs": [], "name": "getCount", "outputs": [ { "name": "", "type": "uint256" } ], "payable": false, "stateMutability": "view", "type": "function" }, { "constant": true, "inputs": [ { "name": "_owner", "type": "address" } ], "name": "getAuctionsOf", "outputs": [ { "name": "", "type": "uint256[]" } ], "payable": false, "stateMutability": "view", "type": "function" }, { "constant": true, "inputs": [ { "name": "_owner", "type": "address" } ], "name": "getAuctionsCountOfOwner", "outputs": [ { "name": "", "type": "uint256" } ], "payable": false, "stateMutability": "view", "type": "function" }, { "constant": true, "inputs": [ { "name": "_auctionId", "type": "uint256" } ], "name": "getAuctionById", "outputs": [ { "name": "name", "type": "string" }, { "name": "price", "type": "uint256" }, { "name": "metadata", "type": "string" }, { "name": "tokenId", "type": "uint256" }, { "name": "repoAddress", "type": "address" }, { "name": "owner", "type": "address" }, { "name": "active", "type": "bool" }, { "name": "finalized", "type": "bool" } ], "payable": false, "stateMutability": "view", "type": "function" } ], "bytecode": "0x608060405234801561001057600080fd5b506116bb806100206000396000f30060806040526004361061008e576000357c0100000000000000000000000000000000000000000000000000000000900463ffffffff1680631626b759146100a057806318111ada146100ed578063571a26a0146102895780639472559f14610425578063a87d942c14610520578063b1b61bfa1461054b578063c8756cda146105e3578063d56aa55814610644575b34801561009a57600080fd5b50600080fd5b3480156100ac57600080fd5b506100eb60048036038101908080359060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061069b565b005b3480156100f957600080fd5b5061011860048036038101908080359060200190929190505050610a04565b6040518080602001898152602001806020018881526020018773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001851515151581526020018415151515815260200183810383528b818151815260200191508051906020019080838360005b838110156101e05780820151818401526020810190506101c5565b50505050905090810190601f16801561020d5780820380516001836020036101000a031916815260200191505b50838103825289818151815260200191508051906020019080838360005b8381101561024657808201518184015260208101905061022b565b50505050905090810190601f1680156102735780820380516001836020036101000a031916815260200191505b509a505050505050505050505060405180910390f35b34801561029557600080fd5b506102b460048036038101908080359060200190929190505050610cca565b6040518080602001898152602001806020018881526020018773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001851515151581526020018415151515815260200183810383528b818151815260200191508051906020019080838360005b8381101561037c578082015181840152602081019050610361565b50505050905090810190601f1680156103a95780820380516001836020036101000a031916815260200191505b50838103825289818151815260200191508051906020019080838360005b838110156103e25780820151818401526020810190506103c7565b50505050905090810190601f16801561040f5780820380516001836020036101000a031916815260200191505b509a505050505050505050505060405180910390f35b34801561043157600080fd5b50610506600480360381019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190803590602001908201803590602001908080601f0160208091040260200160405190810160405280939291908181526020018383808284378201915050505050509192919290803590602001908201803590602001908080601f016020809104026020016040519081016040528093929190818152602001838380828437820191505050505050919291929080359060200190929190505050610eab565b604051808215151515815260200191505060405180910390f35b34801561052c57600080fd5b50610535611293565b6040518082815260200191505060405180910390f35b34801561055757600080fd5b5061058c600480360381019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061129f565b6040518080602001828103825283818151815260200191508051906020019060200280838360005b838110156105cf5780820151818401526020810190506105b4565b505050509050019250505060405180910390f35b3480156105ef57600080fd5b5061062e600480360381019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061133b565b6040518082815260200191505060405180910390f35b34801561065057600080fd5b50610685600480360381019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061136b565b6040518082815260200191505060405180910390f35b6106a3611574565b6000838154811015156106b257fe5b90600052602060002090600602016101006040519081016040529081600082018054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156107665780601f1061073b57610100808354040283529160200191610766565b820191906000526020600020905b81548152906001019060200180831161074957829003601f168201915b5050505050815260200160018201548152602001600282018054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156108125780601f106107e757610100808354040283529160200191610812565b820191906000526020600020905b8154815290600101906020018083116107f557829003601f168201915b50505050508152602001600382015481526020016004820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020016005820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020016005820160149054906101000a900460ff161515151581526020016005820160159054906101000a900460ff161515151581525050905061091d3083836080015184606001516113b7565b156109ff576000808481548110151561093257fe5b906000526020600020906006020160050160146101000a81548160ff021916908315150217905550600160008481548110151561096b57fe5b906000526020600020906006020160050160156101000a81548160ff0219169083151502179055507f357afab190ee87fe0ef1c717f2728d2904d9e415a069d99f4d9382873cb3279d3384604051808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019250505060405180910390a15b505050565b6060600060606000806000806000610a1a611574565b60008a815481101515610a2957fe5b90600052602060002090600602016101006040519081016040529081600082018054600181600116156101000203166002900480601f016020809104026020016040519081016040528092919081815260200182805460018160011615610100020316600290048015610add5780601f10610ab257610100808354040283529160200191610add565b820191906000526020600020905b815481529060010190602001808311610ac057829003601f168201915b5050505050815260200160018201548152602001600282018054600181600116156101000203166002900480601f016020809104026020016040519081016040528092919081815260200182805460018160011615610100020316600290048015610b895780601f10610b5e57610100808354040283529160200191610b89565b820191906000526020600020905b815481529060010190602001808311610b6c57829003601f168201915b50505050508152602001600382015481526020016004820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020016005820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020016005820160149054906101000a900460ff161515151581526020016005820160159054906101000a900460ff1615151515815250509050806000015181602001518260400151836060015184608001518560a001518660c001518760e001518797508595509850985098509850985098509850985050919395975091939597565b600081815481101515610cd957fe5b9060005260206000209060060201600091509050806000018054600181600116156101000203166002900480601f016020809104026020016040519081016040528092919081815260200182805460018160011615610100020316600290048015610d855780601f10610d5a57610100808354040283529160200191610d85565b820191906000526020600020905b815481529060010190602001808311610d6857829003601f168201915b505050505090806001015490806002018054600181600116156101000203166002900480601f016020809104026020016040519081016040528092919081815260200182805460018160011615610100020316600290048015610e295780601f10610dfe57610100808354040283529160200191610e29565b820191906000526020600020905b815481529060010190602001808311610e0c57829003601f168201915b5050505050908060030154908060040160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16908060050160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16908060050160149054906101000a900460ff16908060050160159054906101000a900460ff16905088565b600080610eb6611574565b878760008273ffffffffffffffffffffffffffffffffffffffff16636352211e836040518263ffffffff167c010000000000000000000000000000000000000000000000000000000002815260040180828152602001915050602060405180830381600087803b158015610f2957600080fd5b505af1158015610f3d573d6000803e3d6000fd5b505050506040513d6020811015610f5357600080fd5b810190808051906020019092919050505090503073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16141515610fa057600080fd5b600080549050945088846000018190525086846020018181525050878460400181905250898460600181815250508a846080019073ffffffffffffffffffffffffffffffffffffffff16908173ffffffffffffffffffffffffffffffffffffffff1681525050338460a0019073ffffffffffffffffffffffffffffffffffffffff16908173ffffffffffffffffffffffffffffffffffffffff168152505060018460c001901515908115158152505060008460e00190151590811515815250506000849080600181540180825580915050906001820390600052602060002090600602016000909192909190915060008201518160000190805190602001906110aa9291906115ea565b506020820151816001015560408201518160020190805190602001906110d19291906115ea565b506060820151816003015560808201518160040160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060a08201518160050160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060c08201518160050160146101000a81548160ff02191690831515021790555060e08201518160050160156101000a81548160ff021916908315150217905550505050600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000208590806001815401808255809150509060018203906000526020600020016000909192909190915055507f3249a06bd478adf780bb7930214ad005e9cfa517d63221c0b77f27199d1a58b33386604051808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019250505060405180910390a160019550505050505095945050505050565b60008080549050905090565b606080600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002080548060200260200160405190810160405280929190818152602001828054801561132b57602002820191906000526020600020905b815481526020019060010190808311611317575b5050505050905080915050919050565b60016020528160005260406000208181548110151561135657fe5b90600052602060002001600091509150505481565b6000600160008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020805490509050919050565b6000808390508073ffffffffffffffffffffffffffffffffffffffff1663095ea7b386856040518363ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050600060405180830381600087803b15801561146057600080fd5b505af1158015611474573d6000803e3d6000fd5b505050508073ffffffffffffffffffffffffffffffffffffffff166323b872dd8787866040518463ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019350505050600060405180830381600087803b15801561154f57600080fd5b505af1158015611563573d6000803e3d6000fd5b505050506001915050949350505050565b6101006040519081016040528060608152602001600081526020016060815260200160008152602001600073ffffffffffffffffffffffffffffffffffffffff168152602001600073ffffffffffffffffffffffffffffffffffffffff1681526020016000151581526020016000151581525090565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f1061162b57805160ff1916838001178555611659565b82800160010185558215611659579182015b8281111561165857825182559160200191906001019061163d565b5b509050611666919061166a565b5090565b61168c91905b80821115611688576000816000905550600101611670565b5090565b905600a165627a7a72305820f13c9386c654b4605615dadfd0f2ac571d8d5bce6eeaec5a03d0680d3e36d9ef0029", "deployedBytecode": "0x60806040526004361061008e576000357c0100000000000000000000000000000000000000000000000000000000900463ffffffff1680631626b759146100a057806318111ada146100ed578063571a26a0146102895780639472559f14610425578063a87d942c14610520578063b1b61bfa1461054b578063c8756cda146105e3578063d56aa55814610644575b34801561009a57600080fd5b50600080fd5b3480156100ac57600080fd5b506100eb60048036038101908080359060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061069b565b005b3480156100f957600080fd5b5061011860048036038101908080359060200190929190505050610a04565b6040518080602001898152602001806020018881526020018773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001851515151581526020018415151515815260200183810383528b818151815260200191508051906020019080838360005b838110156101e05780820151818401526020810190506101c5565b50505050905090810190601f16801561020d5780820380516001836020036101000a031916815260200191505b50838103825289818151815260200191508051906020019080838360005b8381101561024657808201518184015260208101905061022b565b50505050905090810190601f1680156102735780820380516001836020036101000a031916815260200191505b509a505050505050505050505060405180910390f35b34801561029557600080fd5b506102b460048036038101908080359060200190929190505050610cca565b6040518080602001898152602001806020018881526020018773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001851515151581526020018415151515815260200183810383528b818151815260200191508051906020019080838360005b8381101561037c578082015181840152602081019050610361565b50505050905090810190601f1680156103a95780820380516001836020036101000a031916815260200191505b50838103825289818151815260200191508051906020019080838360005b838110156103e25780820151818401526020810190506103c7565b50505050905090810190601f16801561040f5780820380516001836020036101000a031916815260200191505b509a505050505050505050505060405180910390f35b34801561043157600080fd5b50610506600480360381019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190803590602001908201803590602001908080601f0160208091040260200160405190810160405280939291908181526020018383808284378201915050505050509192919290803590602001908201803590602001908080601f016020809104026020016040519081016040528093929190818152602001838380828437820191505050505050919291929080359060200190929190505050610eab565b604051808215151515815260200191505060405180910390f35b34801561052c57600080fd5b50610535611293565b6040518082815260200191505060405180910390f35b34801561055757600080fd5b5061058c600480360381019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061129f565b6040518080602001828103825283818151815260200191508051906020019060200280838360005b838110156105cf5780820151818401526020810190506105b4565b505050509050019250505060405180910390f35b3480156105ef57600080fd5b5061062e600480360381019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061133b565b6040518082815260200191505060405180910390f35b34801561065057600080fd5b50610685600480360381019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061136b565b6040518082815260200191505060405180910390f35b6106a3611574565b6000838154811015156106b257fe5b90600052602060002090600602016101006040519081016040529081600082018054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156107665780601f1061073b57610100808354040283529160200191610766565b820191906000526020600020905b81548152906001019060200180831161074957829003601f168201915b5050505050815260200160018201548152602001600282018054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156108125780601f106107e757610100808354040283529160200191610812565b820191906000526020600020905b8154815290600101906020018083116107f557829003601f168201915b50505050508152602001600382015481526020016004820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020016005820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020016005820160149054906101000a900460ff161515151581526020016005820160159054906101000a900460ff161515151581525050905061091d3083836080015184606001516113b7565b156109ff576000808481548110151561093257fe5b906000526020600020906006020160050160146101000a81548160ff021916908315150217905550600160008481548110151561096b57fe5b906000526020600020906006020160050160156101000a81548160ff0219169083151502179055507f357afab190ee87fe0ef1c717f2728d2904d9e415a069d99f4d9382873cb3279d3384604051808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019250505060405180910390a15b505050565b6060600060606000806000806000610a1a611574565b60008a815481101515610a2957fe5b90600052602060002090600602016101006040519081016040529081600082018054600181600116156101000203166002900480601f016020809104026020016040519081016040528092919081815260200182805460018160011615610100020316600290048015610add5780601f10610ab257610100808354040283529160200191610add565b820191906000526020600020905b815481529060010190602001808311610ac057829003601f168201915b5050505050815260200160018201548152602001600282018054600181600116156101000203166002900480601f016020809104026020016040519081016040528092919081815260200182805460018160011615610100020316600290048015610b895780601f10610b5e57610100808354040283529160200191610b89565b820191906000526020600020905b815481529060010190602001808311610b6c57829003601f168201915b50505050508152602001600382015481526020016004820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020016005820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020016005820160149054906101000a900460ff161515151581526020016005820160159054906101000a900460ff1615151515815250509050806000015181602001518260400151836060015184608001518560a001518660c001518760e001518797508595509850985098509850985098509850985050919395975091939597565b600081815481101515610cd957fe5b9060005260206000209060060201600091509050806000018054600181600116156101000203166002900480601f016020809104026020016040519081016040528092919081815260200182805460018160011615610100020316600290048015610d855780601f10610d5a57610100808354040283529160200191610d85565b820191906000526020600020905b815481529060010190602001808311610d6857829003601f168201915b505050505090806001015490806002018054600181600116156101000203166002900480601f016020809104026020016040519081016040528092919081815260200182805460018160011615610100020316600290048015610e295780601f10610dfe57610100808354040283529160200191610e29565b820191906000526020600020905b815481529060010190602001808311610e0c57829003601f168201915b5050505050908060030154908060040160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16908060050160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16908060050160149054906101000a900460ff16908060050160159054906101000a900460ff16905088565b600080610eb6611574565b878760008273ffffffffffffffffffffffffffffffffffffffff16636352211e836040518263ffffffff167c010000000000000000000000000000000000000000000000000000000002815260040180828152602001915050602060405180830381600087803b158015610f2957600080fd5b505af1158015610f3d573d6000803e3d6000fd5b505050506040513d6020811015610f5357600080fd5b810190808051906020019092919050505090503073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16141515610fa057600080fd5b600080549050945088846000018190525086846020018181525050878460400181905250898460600181815250508a846080019073ffffffffffffffffffffffffffffffffffffffff16908173ffffffffffffffffffffffffffffffffffffffff1681525050338460a0019073ffffffffffffffffffffffffffffffffffffffff16908173ffffffffffffffffffffffffffffffffffffffff168152505060018460c001901515908115158152505060008460e00190151590811515815250506000849080600181540180825580915050906001820390600052602060002090600602016000909192909190915060008201518160000190805190602001906110aa9291906115ea565b506020820151816001015560408201518160020190805190602001906110d19291906115ea565b506060820151816003015560808201518160040160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060a08201518160050160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060c08201518160050160146101000a81548160ff02191690831515021790555060e08201518160050160156101000a81548160ff021916908315150217905550505050600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000208590806001815401808255809150509060018203906000526020600020016000909192909190915055507f3249a06bd478adf780bb7930214ad005e9cfa517d63221c0b77f27199d1a58b33386604051808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019250505060405180910390a160019550505050505095945050505050565b60008080549050905090565b606080600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002080548060200260200160405190810160405280929190818152602001828054801561132b57602002820191906000526020600020905b815481526020019060010190808311611317575b5050505050905080915050919050565b60016020528160005260406000208181548110151561135657fe5b90600052602060002001600091509150505481565b6000600160008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020805490509050919050565b6000808390508073ffffffffffffffffffffffffffffffffffffffff1663095ea7b386856040518363ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050600060405180830381600087803b15801561146057600080fd5b505af1158015611474573d6000803e3d6000fd5b505050508073ffffffffffffffffffffffffffffffffffffffff166323b872dd8787866040518463ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019350505050600060405180830381600087803b15801561154f57600080fd5b505af1158015611563573d6000803e3d6000fd5b505050506001915050949350505050565b6101006040519081016040528060608152602001600081526020016060815260200160008152602001600073ffffffffffffffffffffffffffffffffffffffff168152602001600073ffffffffffffffffffffffffffffffffffffffff1681526020016000151581526020016000151581525090565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f1061162b57805160ff1916838001178555611659565b82800160010185558215611659579182015b8281111561165857825182559160200191906001019061163d565b5b509050611666919061166a565b5090565b61168c91905b80821115611688576000816000905550600101611670565b5090565b905600a165627a7a72305820f13c9386c654b4605615dadfd0f2ac571d8d5bce6eeaec5a03d0680d3e36d9ef0029", "sourceMap": "49:2831:0:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;49:2831:0;;;;;;;", "deployedSourceMap": "49:2831:0:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;49:2831:0;507:8;;;1366:350;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1366:350:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2366:397;;8:9:-1;5:2;;;30:1;27;20:12;5:2;2366:397:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;2366:397:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;2366:397:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;70:25;;8:9:-1;5:2;;;30:1;27;20:12;5:2;70:25:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;70:25:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;70:25:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;703:660;;8:9:-1;5:2;;;30:1;27;20:12;5:2;703:660:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2003:80;;8:9:-1;5:2;;;30:1;27;20:12;5:2;2003:80:0;;;;;;;;;;;;;;;;;;;;;;;2086:153;;8:9:-1;5:2;;;30:1;27;20:12;5:2;2086:153:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;2086:153:0;;;;;;;;;;;;;;;;;99:46;;8:9:-1;5:2;;;30:1;27;20:12;5:2;99:46:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2242:121;;8:9:-1;5:2;;;30:1;27;20:12;5:2;2242:121:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1366:350;1432:24;;:::i;:::-;1459:8;1468:10;1459:20;;;;;;;;;;;;;;;;;;;;1432:47;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1486:80;1513:4;1520:3;1525:9;:21;;;1548:9;:17;;;1486:18;:80::i;:::-;1483:230;;;1605:5;1575:8;1584:10;1575:20;;;;;;;;;;;;;;;;;;;;:27;;;:35;;;;;;;;;;;;;;;;;;1651:4;1618:8;1627:10;1618:20;;;;;;;;;;;;;;;;;;;;:30;;;:37;;;;;;;;;;;;;;;;;;1668:40;1685:10;1697;1668:40;;;;;;;;;;;;;;;;;;;;;;;;;;;;1483:230;1366:350;;;:::o;2366:397::-;2434:11;2449:13;2466:15;2485;2504:19;2527:13;2544:11;2559:14;2579:18;;:::i;:::-;2600:8;2609:10;2600:20;;;;;;;;;;;;;;;;;;;;2579:41;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2636:3;:8;;;2649:3;:9;;;2663:3;:12;;;2680:3;:11;;;2696:3;:15;;;2716:3;:9;;;2730:3;:10;;;2745:3;:13;;;2624:135;;;;;;;;;;;;;;;;;;;;;;2366:397;;;;;;;;;;:::o;70:25::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;703:660::-;880:4;890:14;926:25;;:::i;:::-;848:12;862:8;595:16;620:12;614:27;;;642:8;614:37;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;614:37:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;614:37:0;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;614:37:0;;;;;;;;;;;;;;;;595:56;;684:4;664:25;;:8;:25;;;656:34;;;;;;;;907:8;:15;;;;890:32;;973:13;955:10;:15;;:31;;;;1009:6;990:10;:16;;:25;;;;;1041:9;1019:10;:19;;:31;;;;1075:8;1054:10;:18;;:29;;;;;1112:12;1087:10;:22;;:37;;;;;;;;;;;1147:10;1128;:16;;:29;;;;;;;;;;;1181:4;1161:10;:17;;:24;;;;;;;;;;;1218:5;1195:10;:20;;:28;;;;;;;;;;;1228:8;1242:10;1228:25;;39:1:-1;33:3;27:10;23:18;57:10;52:3;45:23;79:10;72:17;;0:93;1228:25:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1257:12;:24;1270:10;1257:24;;;;;;;;;;;;;;;1287:9;1257:40;;39:1:-1;33:3;27:10;23:18;57:10;52:3;45:23;79:10;72:17;;0:93;1257:40:0;;;;;;;;;;;;;;;;;;;;;;1307:37;1322:10;1334:9;1307:37;;;;;;;;;;;;;;;;;;;;;;;;;;;;1355:4;1348:11;;703:660;;;;;;;;;;;;:::o;2003:80::-;2047:4;2064:8;:15;;;;2057:22;;2003:80;:::o;2086:153::-;2149:6;2161:27;2191:12;:20;2204:6;2191:20;;;;;;;;;;;;;;;2161:50;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2222:13;2215:20;;2086:153;;;;:::o;99:46::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;2242:121::-;2315:4;2332:12;:20;2345:6;2332:20;;;;;;;;;;;;;;;:27;;;;2325:34;;2242:121;;;:::o;1719:278::-;1832:4;1842:20;1871:12;1842:42;;1888:14;:22;;;1911:3;1916:8;1888:37;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1888:37:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1888:37:0;;;;1929:14;:27;;;1957:5;1964:3;1969:8;1929:49;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1929:49:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1929:49:0;;;;1989:4;1982:11;;1719:278;;;;;;;:::o;49:2831::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;:::o;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o", "source": "pragma solidity ^0.4.24;\n\nimport \"./MyNFT.sol\";\n\ncontract Auctions {\n\tAuction[] public auctions;\n \tmapping(address => uint[]) public auctionOwner;\n\n\tstruct Auction {\n\t string name; // 제목\n\t uint256 price; // 가격\n\t string metadata; // 메타데이터 : ipfs hash\n\t uint256 tokenId; // 토큰 아이디\n\t address repoAddress; // nft 컨트랙트 어드레스\n\t address owner; // 소유자\t\t\t\t\n\t bool active; //활성화 여부\n\t bool finalized; //판매 종료여부\n\t}\n\n\tfunction() public {\n\t revert();\n\t}\n\n\tmodifier contractIsNFTOwner(address _repoAddress, uint256 _tokenId) {\n\t address nftOwner = MyNFT(_repoAddress).ownerOf(_tokenId);\n\t require(nftOwner == address(this));\n\t _;\n\t}\n\n\tfunction createAuction(address _repoAddress, uint256 _tokenId, string _auctionTitle, string _metadata, uint256 _price) public contractIsNFTOwner(_repoAddress, _tokenId) returns(bool) {\n\t\tuint auctionId = auctions.length;\n\t\tAuction memory newAuction;\n\t\tnewAuction.name = _auctionTitle;\n\t\tnewAuction.price = _price;\n\t\tnewAuction.metadata = _metadata;\n\t\tnewAuction.tokenId = _tokenId;\n\t\tnewAuction.repoAddress = _repoAddress;\n\t\tnewAuction.owner = msg.sender;\n\t\tnewAuction.active = true;\n newAuction.finalized = false;\n\n\t\tauctions.push(newAuction);\n\t\tauctionOwner[msg.sender].push(auctionId);\n\n\t\temit AuctionCreated(msg.sender, auctionId);\n\t\treturn true;\n\t}\n\n\tfunction finalizeAuction(uint _auctionId, address _to) public {\n\t\tAuction memory myAuction = auctions[_auctionId];\n\t\tif(approveAndTransfer(address(this), _to, myAuction.repoAddress, myAuction.tokenId)){\n\t\t auctions[_auctionId].active = false;\n\t\t auctions[_auctionId].finalized = true;\n\t\t emit AuctionFinalized(msg.sender, _auctionId);\n\t\t}\n\t}\n\n\tfunction approveAndTransfer(address _from, address _to, address _repoAddress, uint256 _tokenId) internal returns(bool) {\n\t\tMyNFT remoteContract = MyNFT(_repoAddress);\n\t\tremoteContract.approve(_to, _tokenId);\n\t\tremoteContract.transferFrom(_from, _to, _tokenId);\n\t\treturn true;\n\t}\n\n function getCount() public constant returns(uint) {\n\t\treturn auctions.length;\n\t}\n\n\tfunction getAuctionsOf(address _owner) public constant returns(uint[]) {\n\t\tuint[] memory ownedAuctions = auctionOwner[_owner];\n\t\treturn ownedAuctions;\n\t}\n\n\tfunction getAuctionsCountOfOwner(address _owner) public constant returns(uint) {\n\t\treturn auctionOwner[_owner].length;\n\t}\n\n\tfunction getAuctionById(uint _auctionId) public constant returns(\n\t\tstring name,\n\t\tuint256 price,\n\t\tstring metadata,\n\t\tuint256 tokenId,\n\t\taddress repoAddress,\n\t\taddress owner,\n\t\tbool active,\n\t\tbool finalized) {\n\t\tAuction memory auc = auctions[_auctionId];\n\t\treturn (\n\t\t\tauc.name,\n\t\t\tauc.price,\n\t\t\tauc.metadata,\n\t\t\tauc.tokenId,\n\t\t\tauc.repoAddress,\n\t\t\tauc.owner,\n\t\t\tauc.active,\n\t\t\tauc.finalized);\n\t}\n\n\tevent AuctionCreated(address _owner, uint _auctionId);\n\tevent AuctionFinalized(address _owner, uint _auctionId);\n}\n", "sourcePath": "/Users/willpark/Desktop/bookwork-klaytn/project_codes/nftbapp/backend-nftdapp/contracts/Auctions.sol", "ast": { "absolutePath": "/Users/willpark/Desktop/bookwork-klaytn/project_codes/nftbapp/backend-nftdapp/contracts/Auctions.sol", "exportedSymbols": { "Auctions": [ 341 ] }, "id": 342, "nodeType": "SourceUnit", "nodes": [ { "id": 1, "literals": [ "solidity", "^", "0.4", ".24" ], "nodeType": "PragmaDirective", "src": "0:24:0" }, { "absolutePath": "/Users/willpark/Desktop/bookwork-klaytn/project_codes/nftbapp/backend-nftdapp/contracts/MyNFT.sol", "file": "./MyNFT.sol", "id": 2, "nodeType": "ImportDirective", "scope": 342, "sourceUnit": 452, "src": "26:21:0", "symbolAliases": [], "unitAlias": "" }, { "baseContracts": [], "contractDependencies": [], "contractKind": "contract", "documentation": null, "fullyImplemented": true, "id": 341, "linearizedBaseContracts": [ 341 ], "name": "Auctions", "nodeType": "ContractDefinition", "nodes": [ { "constant": false, "id": 5, "name": "auctions", "nodeType": "VariableDeclaration", "scope": 341, "src": "70:25:0", "stateVariable": true, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_array$_t_struct$_Auction_$27_storage_$dyn_storage", "typeString": "struct Auctions.Auction[]" }, "typeName": { "baseType": { "contractScope": null, "id": 3, "name": "Auction", "nodeType": "UserDefinedTypeName", "referencedDeclaration": 27, "src": "70:7:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_storage_ptr", "typeString": "struct Auctions.Auction" } }, "id": 4, "length": null, "nodeType": "ArrayTypeName", "src": "70:9:0", "typeDescriptions": { "typeIdentifier": "t_array$_t_struct$_Auction_$27_storage_$dyn_storage_ptr", "typeString": "struct Auctions.Auction[]" } }, "value": null, "visibility": "public" }, { "constant": false, "id": 10, "name": "auctionOwner", "nodeType": "VariableDeclaration", "scope": 341, "src": "99:46:0", "stateVariable": true, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_array$_t_uint256_$dyn_storage_$", "typeString": "mapping(address => uint256[])" }, "typeName": { "id": 9, "keyType": { "id": 6, "name": "address", "nodeType": "ElementaryTypeName", "src": "107:7:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "nodeType": "Mapping", "src": "99:26:0", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_array$_t_uint256_$dyn_storage_$", "typeString": "mapping(address => uint256[])" }, "valueType": { "baseType": { "id": 7, "name": "uint", "nodeType": "ElementaryTypeName", "src": "118:4:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "id": 8, "length": null, "nodeType": "ArrayTypeName", "src": "118:6:0", "typeDescriptions": { "typeIdentifier": "t_array$_t_uint256_$dyn_storage_ptr", "typeString": "uint256[]" } } }, "value": null, "visibility": "public" }, { "canonicalName": "Auctions.Auction", "id": 27, "members": [ { "constant": false, "id": 12, "name": "name", "nodeType": "VariableDeclaration", "scope": 27, "src": "169:11:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_string_storage_ptr", "typeString": "string" }, "typeName": { "id": 11, "name": "string", "nodeType": "ElementaryTypeName", "src": "169:6:0", "typeDescriptions": { "typeIdentifier": "t_string_storage_ptr", "typeString": "string" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 14, "name": "price", "nodeType": "VariableDeclaration", "scope": 27, "src": "195:13:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 13, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "195:7:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 16, "name": "metadata", "nodeType": "VariableDeclaration", "scope": 27, "src": "223:15:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_string_storage_ptr", "typeString": "string" }, "typeName": { "id": 15, "name": "string", "nodeType": "ElementaryTypeName", "src": "223:6:0", "typeDescriptions": { "typeIdentifier": "t_string_storage_ptr", "typeString": "string" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 18, "name": "tokenId", "nodeType": "VariableDeclaration", "scope": 27, "src": "274:15:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 17, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "274:7:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 20, "name": "repoAddress", "nodeType": "VariableDeclaration", "scope": 27, "src": "314:19:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 19, "name": "address", "nodeType": "ElementaryTypeName", "src": "314:7:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 22, "name": "owner", "nodeType": "VariableDeclaration", "scope": 27, "src": "371:13:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 21, "name": "address", "nodeType": "ElementaryTypeName", "src": "371:7:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 24, "name": "active", "nodeType": "VariableDeclaration", "scope": 27, "src": "406:11:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" }, "typeName": { "id": 23, "name": "bool", "nodeType": "ElementaryTypeName", "src": "406:4:0", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 26, "name": "finalized", "nodeType": "VariableDeclaration", "scope": 27, "src": "441:14:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" }, "typeName": { "id": 25, "name": "bool", "nodeType": "ElementaryTypeName", "src": "441:4:0", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "value": null, "visibility": "internal" } ], "name": "Auction", "nodeType": "StructDefinition", "scope": 341, "src": "149:332:0", "visibility": "public" }, { "body": { "id": 33, "nodeType": "Block", "src": "502:17:0", "statements": [ { "expression": { "argumentTypes": null, "arguments": [], "expression": { "argumentTypes": [], "id": 30, "name": "revert", "nodeType": "Identifier", "overloadedDeclarations": [ 1761, 1762 ], "referencedDeclaration": 1761, "src": "507:6:0", "typeDescriptions": { "typeIdentifier": "t_function_revert_pure$__$returns$__$", "typeString": "function () pure" } }, "id": 31, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "507:8:0", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, "id": 32, "nodeType": "ExpressionStatement", "src": "507:8:0" } ] }, "documentation": null, "id": 34, "implemented": true, "isConstructor": false, "isDeclaredConst": false, "modifiers": [], "name": "", "nodeType": "FunctionDefinition", "parameters": { "id": 28, "nodeType": "ParameterList", "parameters": [], "src": "492:2:0" }, "payable": false, "returnParameters": { "id": 29, "nodeType": "ParameterList", "parameters": [], "src": "502:0:0" }, "scope": 341, "src": "484:35:0", "stateMutability": "nonpayable", "superFunction": null, "visibility": "public" }, { "body": { "id": 58, "nodeType": "Block", "src": "590:110:0", "statements": [ { "assignments": [ 41 ], "declarations": [ { "constant": false, "id": 41, "name": "nftOwner", "nodeType": "VariableDeclaration", "scope": 59, "src": "595:16:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 40, "name": "address", "nodeType": "ElementaryTypeName", "src": "595:7:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "value": null, "visibility": "internal" } ], "id": 48, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "id": 46, "name": "_tokenId", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 38, "src": "642:8:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_uint256", "typeString": "uint256" } ], "expression": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "id": 43, "name": "_repoAddress", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 36, "src": "620:12:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_address", "typeString": "address" } ], "id": 42, "name": "MyNFT", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 451, "src": "614:5:0", "typeDescriptions": { "typeIdentifier": "t_type$_t_contract$_MyNFT_$451_$", "typeString": "type(contract MyNFT)" } }, "id": 44, "isConstant": false, "isLValue": false, "isPure": false, "kind": "typeConversion", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "614:19:0", "typeDescriptions": { "typeIdentifier": "t_contract$_MyNFT_$451", "typeString": "contract MyNFT" } }, "id": 45, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "ownerOf", "nodeType": "MemberAccess", "referencedDeclaration": 895, "src": "614:27:0", "typeDescriptions": { "typeIdentifier": "t_function_external_view$_t_uint256_$returns$_t_address_$", "typeString": "function (uint256) view external returns (address)" } }, "id": 47, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "614:37:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "nodeType": "VariableDeclarationStatement", "src": "595:56:0" }, { "expression": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "commonType": { "typeIdentifier": "t_address", "typeString": "address" }, "id": 54, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "argumentTypes": null, "id": 50, "name": "nftOwner", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 41, "src": "664:8:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "nodeType": "BinaryOperation", "operator": "==", "rightExpression": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "id": 52, "name": "this", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 1793, "src": "684:4:0", "typeDescriptions": { "typeIdentifier": "t_contract$_Auctions_$341", "typeString": "contract Auctions" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_contract$_Auctions_$341", "typeString": "contract Auctions" } ], "id": 51, "isConstant": false, "isLValue": false, "isPure": true, "lValueRequested": false, "nodeType": "ElementaryTypeNameExpression", "src": "676:7:0", "typeDescriptions": { "typeIdentifier": "t_type$_t_address_$", "typeString": "type(address)" }, "typeName": "address" }, "id": 53, "isConstant": false, "isLValue": false, "isPure": false, "kind": "typeConversion", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "676:13:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "src": "664:25:0", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_bool", "typeString": "bool" } ], "id": 49, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ 1759, 1760 ], "referencedDeclaration": 1759, "src": "656:7:0", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$", "typeString": "function (bool) pure" } }, "id": 55, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "656:34:0", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, "id": 56, "nodeType": "ExpressionStatement", "src": "656:34:0" }, { "id": 57, "nodeType": "PlaceholderStatement", "src": "695:1:0" } ] }, "documentation": null, "id": 59, "name": "contractIsNFTOwner", "nodeType": "ModifierDefinition", "parameters": { "id": 39, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 36, "name": "_repoAddress", "nodeType": "VariableDeclaration", "scope": 59, "src": "550:20:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 35, "name": "address", "nodeType": "ElementaryTypeName", "src": "550:7:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 38, "name": "_tokenId", "nodeType": "VariableDeclaration", "scope": 59, "src": "572:16:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 37, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "572:7:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "value": null, "visibility": "internal" } ], "src": "549:40:0" }, "src": "522:178:0", "visibility": "internal" }, { "body": { "id": 157, "nodeType": "Block", "src": "886:477:0", "statements": [ { "assignments": [ 79 ], "declarations": [ { "constant": false, "id": 79, "name": "auctionId", "nodeType": "VariableDeclaration", "scope": 158, "src": "890:14:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 78, "name": "uint", "nodeType": "ElementaryTypeName", "src": "890:4:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "value": null, "visibility": "internal" } ], "id": 82, "initialValue": { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 80, "name": "auctions", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 5, "src": "907:8:0", "typeDescriptions": { "typeIdentifier": "t_array$_t_struct$_Auction_$27_storage_$dyn_storage", "typeString": "struct Auctions.Auction storage ref[] storage ref" } }, "id": 81, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "memberName": "length", "nodeType": "MemberAccess", "referencedDeclaration": null, "src": "907:15:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "VariableDeclarationStatement", "src": "890:32:0" }, { "assignments": [], "declarations": [ { "constant": false, "id": 84, "name": "newAuction", "nodeType": "VariableDeclaration", "scope": 158, "src": "926:25:0", "stateVariable": false, "storageLocation": "memory", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction" }, "typeName": { "contractScope": null, "id": 83, "name": "Auction", "nodeType": "UserDefinedTypeName", "referencedDeclaration": 27, "src": "926:7:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_storage_ptr", "typeString": "struct Auctions.Auction" } }, "value": null, "visibility": "internal" } ], "id": 85, "initialValue": null, "nodeType": "VariableDeclarationStatement", "src": "926:25:0" }, { "expression": { "argumentTypes": null, "id": 90, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 86, "name": "newAuction", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 84, "src": "955:10:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction memory" } }, "id": 88, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": true, "memberName": "name", "nodeType": "MemberAccess", "referencedDeclaration": 12, "src": "955:15:0", "typeDescriptions": { "typeIdentifier": "t_string_memory", "typeString": "string memory" } }, "nodeType": "Assignment", "operator": "=", "rightHandSide": { "argumentTypes": null, "id": 89, "name": "_auctionTitle", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 65, "src": "973:13:0", "typeDescriptions": { "typeIdentifier": "t_string_memory_ptr", "typeString": "string memory" } }, "src": "955:31:0", "typeDescriptions": { "typeIdentifier": "t_string_memory", "typeString": "string memory" } }, "id": 91, "nodeType": "ExpressionStatement", "src": "955:31:0" }, { "expression": { "argumentTypes": null, "id": 96, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 92, "name": "newAuction", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 84, "src": "990:10:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction memory" } }, "id": 94, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": true, "memberName": "price", "nodeType": "MemberAccess", "referencedDeclaration": 14, "src": "990:16:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "Assignment", "operator": "=", "rightHandSide": { "argumentTypes": null, "id": 95, "name": "_price", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 69, "src": "1009:6:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "src": "990:25:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "id": 97, "nodeType": "ExpressionStatement", "src": "990:25:0" }, { "expression": { "argumentTypes": null, "id": 102, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 98, "name": "newAuction", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 84, "src": "1019:10:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction memory" } }, "id": 100, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": true, "memberName": "metadata", "nodeType": "MemberAccess", "referencedDeclaration": 16, "src": "1019:19:0", "typeDescriptions": { "typeIdentifier": "t_string_memory", "typeString": "string memory" } }, "nodeType": "Assignment", "operator": "=", "rightHandSide": { "argumentTypes": null, "id": 101, "name": "_metadata", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 67, "src": "1041:9:0", "typeDescriptions": { "typeIdentifier": "t_string_memory_ptr", "typeString": "string memory" } }, "src": "1019:31:0", "typeDescriptions": { "typeIdentifier": "t_string_memory", "typeString": "string memory" } }, "id": 103, "nodeType": "ExpressionStatement", "src": "1019:31:0" }, { "expression": { "argumentTypes": null, "id": 108, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 104, "name": "newAuction", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 84, "src": "1054:10:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction memory" } }, "id": 106, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": true, "memberName": "tokenId", "nodeType": "MemberAccess", "referencedDeclaration": 18, "src": "1054:18:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "Assignment", "operator": "=", "rightHandSide": { "argumentTypes": null, "id": 107, "name": "_tokenId", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 63, "src": "1075:8:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "src": "1054:29:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "id": 109, "nodeType": "ExpressionStatement", "src": "1054:29:0" }, { "expression": { "argumentTypes": null, "id": 114, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 110, "name": "newAuction", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 84, "src": "1087:10:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction memory" } }, "id": 112, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": true, "memberName": "repoAddress", "nodeType": "MemberAccess", "referencedDeclaration": 20, "src": "1087:22:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "nodeType": "Assignment", "operator": "=", "rightHandSide": { "argumentTypes": null, "id": 113, "name": "_repoAddress", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 61, "src": "1112:12:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "src": "1087:37:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "id": 115, "nodeType": "ExpressionStatement", "src": "1087:37:0" }, { "expression": { "argumentTypes": null, "id": 121, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 116, "name": "newAuction", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 84, "src": "1128:10:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction memory" } }, "id": 118, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": true, "memberName": "owner", "nodeType": "MemberAccess", "referencedDeclaration": 22, "src": "1128:16:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "nodeType": "Assignment", "operator": "=", "rightHandSide": { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 119, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 1756, "src": "1147:3:0", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, "id": 120, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, "src": "1147:10:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "src": "1128:29:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "id": 122, "nodeType": "ExpressionStatement", "src": "1128:29:0" }, { "expression": { "argumentTypes": null, "id": 127, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 123, "name": "newAuction", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 84, "src": "1161:10:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction memory" } }, "id": 125, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": true, "memberName": "active", "nodeType": "MemberAccess", "referencedDeclaration": 24, "src": "1161:17:0", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "nodeType": "Assignment", "operator": "=", "rightHandSide": { "argumentTypes": null, "hexValue": "74727565", "id": 126, "isConstant": false, "isLValue": false, "isPure": true, "kind": "bool", "lValueRequested": false, "nodeType": "Literal", "src": "1181:4:0", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" }, "value": "true" }, "src": "1161:24:0", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "id": 128, "nodeType": "ExpressionStatement", "src": "1161:24:0" }, { "expression": { "argumentTypes": null, "id": 133, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 129, "name": "newAuction", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 84, "src": "1195:10:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction memory" } }, "id": 131, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": true, "memberName": "finalized", "nodeType": "MemberAccess", "referencedDeclaration": 26, "src": "1195:20:0", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "nodeType": "Assignment", "operator": "=", "rightHandSide": { "argumentTypes": null, "hexValue": "66616c7365", "id": 132, "isConstant": false, "isLValue": false, "isPure": true, "kind": "bool", "lValueRequested": false, "nodeType": "Literal", "src": "1218:5:0", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" }, "value": "false" }, "src": "1195:28:0", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "id": 134, "nodeType": "ExpressionStatement", "src": "1195:28:0" }, { "expression": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "id": 138, "name": "newAuction", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 84, "src": "1242:10:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction memory" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction memory" } ], "expression": { "argumentTypes": null, "id": 135, "name": "auctions", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 5, "src": "1228:8:0", "typeDescriptions": { "typeIdentifier": "t_array$_t_struct$_Auction_$27_storage_$dyn_storage", "typeString": "struct Auctions.Auction storage ref[] storage ref" } }, "id": 137, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "push", "nodeType": "MemberAccess", "referencedDeclaration": null, "src": "1228:13:0", "typeDescriptions": { "typeIdentifier": "t_function_arraypush_nonpayable$_t_struct$_Auction_$27_storage_$returns$_t_uint256_$", "typeString": "function (struct Auctions.Auction storage ref) returns (uint256)" } }, "id": 139, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "1228:25:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "id": 140, "nodeType": "ExpressionStatement", "src": "1228:25:0" }, { "expression": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "id": 146, "name": "auctionId", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 79, "src": "1287:9:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_uint256", "typeString": "uint256" } ], "expression": { "argumentTypes": null, "baseExpression": { "argumentTypes": null, "id": 141, "name": "auctionOwner", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 10, "src": "1257:12:0", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_array$_t_uint256_$dyn_storage_$", "typeString": "mapping(address => uint256[] storage ref)" } }, "id": 144, "indexExpression": { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 142, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 1756, "src": "1270:3:0", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, "id": 143, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, "src": "1270:10:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", "src": "1257:24:0", "typeDescriptions": { "typeIdentifier": "t_array$_t_uint256_$dyn_storage", "typeString": "uint256[] storage ref" } }, "id": 145, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "push", "nodeType": "MemberAccess", "referencedDeclaration": null, "src": "1257:29:0", "typeDescriptions": { "typeIdentifier": "t_function_arraypush_nonpayable$_t_uint256_$returns$_t_uint256_$", "typeString": "function (uint256) returns (uint256)" } }, "id": 147, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "1257:40:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "id": 148, "nodeType": "ExpressionStatement", "src": "1257:40:0" }, { "eventCall": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 150, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 1756, "src": "1322:3:0", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, "id": 151, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, "src": "1322:10:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, { "argumentTypes": null, "id": 152, "name": "auctionId", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 79, "src": "1334:9:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_address", "typeString": "address" }, { "typeIdentifier": "t_uint256", "typeString": "uint256" } ], "id": 149, "name": "AuctionCreated", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 334, "src": "1307:14:0", "typeDescriptions": { "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$returns$__$", "typeString": "function (address,uint256)" } }, "id": 153, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "1307:37:0", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, "id": 154, "nodeType": "EmitStatement", "src": "1302:42:0" }, { "expression": { "argumentTypes": null, "hexValue": "74727565", "id": 155, "isConstant": false, "isLValue": false, "isPure": true, "kind": "bool", "lValueRequested": false, "nodeType": "Literal", "src": "1355:4:0", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" }, "value": "true" }, "functionReturnParameters": 77, "id": 156, "nodeType": "Return", "src": "1348:11:0" } ] }, "documentation": null, "id": 158, "implemented": true, "isConstructor": false, "isDeclaredConst": false, "modifiers": [ { "arguments": [ { "argumentTypes": null, "id": 72, "name": "_repoAddress", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 61, "src": "848:12:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, { "argumentTypes": null, "id": 73, "name": "_tokenId", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 63, "src": "862:8:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } } ], "id": 74, "modifierName": { "argumentTypes": null, "id": 71, "name": "contractIsNFTOwner", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 59, "src": "829:18:0", "typeDescriptions": { "typeIdentifier": "t_modifier$_t_address_$_t_uint256_$", "typeString": "modifier (address,uint256)" } }, "nodeType": "ModifierInvocation", "src": "829:42:0" } ], "name": "createAuction", "nodeType": "FunctionDefinition", "parameters": { "id": 70, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 61, "name": "_repoAddress", "nodeType": "VariableDeclaration", "scope": 158, "src": "726:20:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 60, "name": "address", "nodeType": "ElementaryTypeName", "src": "726:7:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 63, "name": "_tokenId", "nodeType": "VariableDeclaration", "scope": 158, "src": "748:16:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 62, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "748:7:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 65, "name": "_auctionTitle", "nodeType": "VariableDeclaration", "scope": 158, "src": "766:20:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_string_memory_ptr", "typeString": "string" }, "typeName": { "id": 64, "name": "string", "nodeType": "ElementaryTypeName", "src": "766:6:0", "typeDescriptions": { "typeIdentifier": "t_string_storage_ptr", "typeString": "string" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 67, "name": "_metadata", "nodeType": "VariableDeclaration", "scope": 158, "src": "788:16:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_string_memory_ptr", "typeString": "string" }, "typeName": { "id": 66, "name": "string", "nodeType": "ElementaryTypeName", "src": "788:6:0", "typeDescriptions": { "typeIdentifier": "t_string_storage_ptr", "typeString": "string" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 69, "name": "_price", "nodeType": "VariableDeclaration", "scope": 158, "src": "806:14:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 68, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "806:7:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "value": null, "visibility": "internal" } ], "src": "725:96:0" }, "payable": false, "returnParameters": { "id": 77, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 76, "name": "", "nodeType": "VariableDeclaration", "scope": 158, "src": "880:4:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" }, "typeName": { "id": 75, "name": "bool", "nodeType": "ElementaryTypeName", "src": "880:4:0", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "value": null, "visibility": "internal" } ], "src": "879:6:0" }, "scope": 341, "src": "703:660:0", "stateMutability": "nonpayable", "superFunction": null, "visibility": "public" }, { "body": { "id": 203, "nodeType": "Block", "src": "1428:288:0", "statements": [ { "assignments": [ 166 ], "declarations": [ { "constant": false, "id": 166, "name": "myAuction", "nodeType": "VariableDeclaration", "scope": 204, "src": "1432:24:0", "stateVariable": false, "storageLocation": "memory", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction" }, "typeName": { "contractScope": null, "id": 165, "name": "Auction", "nodeType": "UserDefinedTypeName", "referencedDeclaration": 27, "src": "1432:7:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_storage_ptr", "typeString": "struct Auctions.Auction" } }, "value": null, "visibility": "internal" } ], "id": 170, "initialValue": { "argumentTypes": null, "baseExpression": { "argumentTypes": null, "id": 167, "name": "auctions", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 5, "src": "1459:8:0", "typeDescriptions": { "typeIdentifier": "t_array$_t_struct$_Auction_$27_storage_$dyn_storage", "typeString": "struct Auctions.Auction storage ref[] storage ref" } }, "id": 169, "indexExpression": { "argumentTypes": null, "id": 168, "name": "_auctionId", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 160, "src": "1468:10:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", "src": "1459:20:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_storage", "typeString": "struct Auctions.Auction storage ref" } }, "nodeType": "VariableDeclarationStatement", "src": "1432:47:0" }, { "condition": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "id": 173, "name": "this", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 1793, "src": "1513:4:0", "typeDescriptions": { "typeIdentifier": "t_contract$_Auctions_$341", "typeString": "contract Auctions" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_contract$_Auctions_$341", "typeString": "contract Auctions" } ], "id": 172, "isConstant": false, "isLValue": false, "isPure": true, "lValueRequested": false, "nodeType": "ElementaryTypeNameExpression", "src": "1505:7:0", "typeDescriptions": { "typeIdentifier": "t_type$_t_address_$", "typeString": "type(address)" }, "typeName": "address" }, "id": 174, "isConstant": false, "isLValue": false, "isPure": false, "kind": "typeConversion", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "1505:13:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, { "argumentTypes": null, "id": 175, "name": "_to", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 162, "src": "1520:3:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 176, "name": "myAuction", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 166, "src": "1525:9:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction memory" } }, "id": 177, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "memberName": "repoAddress", "nodeType": "MemberAccess", "referencedDeclaration": 20, "src": "1525:21:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 178, "name": "myAuction", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 166, "src": "1548:9:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction memory" } }, "id": 179, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "memberName": "tokenId", "nodeType": "MemberAccess", "referencedDeclaration": 18, "src": "1548:17:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_address", "typeString": "address" }, { "typeIdentifier": "t_address", "typeString": "address" }, { "typeIdentifier": "t_address", "typeString": "address" }, { "typeIdentifier": "t_uint256", "typeString": "uint256" } ], "id": 171, "name": "approveAndTransfer", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 241, "src": "1486:18:0", "typeDescriptions": { "typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_address_$_t_address_$_t_uint256_$returns$_t_bool_$", "typeString": "function (address,address,address,uint256) returns (bool)" } }, "id": 180, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "1486:80:0", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "falseBody": null, "id": 202, "nodeType": "IfStatement", "src": "1483:230:0", "trueBody": { "id": 201, "nodeType": "Block", "src": "1567:146:0", "statements": [ { "expression": { "argumentTypes": null, "id": 186, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, "expression": { "argumentTypes": null, "baseExpression": { "argumentTypes": null, "id": 181, "name": "auctions", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 5, "src": "1575:8:0", "typeDescriptions": { "typeIdentifier": "t_array$_t_struct$_Auction_$27_storage_$dyn_storage", "typeString": "struct Auctions.Auction storage ref[] storage ref" } }, "id": 183, "indexExpression": { "argumentTypes": null, "id": 182, "name": "_auctionId", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 160, "src": "1584:10:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", "src": "1575:20:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_storage", "typeString": "struct Auctions.Auction storage ref" } }, "id": 184, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": true, "memberName": "active", "nodeType": "MemberAccess", "referencedDeclaration": 24, "src": "1575:27:0", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "nodeType": "Assignment", "operator": "=", "rightHandSide": { "argumentTypes": null, "hexValue": "66616c7365", "id": 185, "isConstant": false, "isLValue": false, "isPure": true, "kind": "bool", "lValueRequested": false, "nodeType": "Literal", "src": "1605:5:0", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" }, "value": "false" }, "src": "1575:35:0", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "id": 187, "nodeType": "ExpressionStatement", "src": "1575:35:0" }, { "expression": { "argumentTypes": null, "id": 193, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, "expression": { "argumentTypes": null, "baseExpression": { "argumentTypes": null, "id": 188, "name": "auctions", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 5, "src": "1618:8:0", "typeDescriptions": { "typeIdentifier": "t_array$_t_struct$_Auction_$27_storage_$dyn_storage", "typeString": "struct Auctions.Auction storage ref[] storage ref" } }, "id": 190, "indexExpression": { "argumentTypes": null, "id": 189, "name": "_auctionId", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 160, "src": "1627:10:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", "src": "1618:20:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_storage", "typeString": "struct Auctions.Auction storage ref" } }, "id": 191, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": true, "memberName": "finalized", "nodeType": "MemberAccess", "referencedDeclaration": 26, "src": "1618:30:0", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "nodeType": "Assignment", "operator": "=", "rightHandSide": { "argumentTypes": null, "hexValue": "74727565", "id": 192, "isConstant": false, "isLValue": false, "isPure": true, "kind": "bool", "lValueRequested": false, "nodeType": "Literal", "src": "1651:4:0", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" }, "value": "true" }, "src": "1618:37:0", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "id": 194, "nodeType": "ExpressionStatement", "src": "1618:37:0" }, { "eventCall": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 196, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 1756, "src": "1685:3:0", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, "id": 197, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, "src": "1685:10:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, { "argumentTypes": null, "id": 198, "name": "_auctionId", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 160, "src": "1697:10:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_address", "typeString": "address" }, { "typeIdentifier": "t_uint256", "typeString": "uint256" } ], "id": 195, "name": "AuctionFinalized", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 340, "src": "1668:16:0", "typeDescriptions": { "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$returns$__$", "typeString": "function (address,uint256)" } }, "id": 199, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "1668:40:0", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, "id": 200, "nodeType": "EmitStatement", "src": "1663:45:0" } ] } } ] }, "documentation": null, "id": 204, "implemented": true, "isConstructor": false, "isDeclaredConst": false, "modifiers": [], "name": "finalizeAuction", "nodeType": "FunctionDefinition", "parameters": { "id": 163, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 160, "name": "_auctionId", "nodeType": "VariableDeclaration", "scope": 204, "src": "1391:15:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 159, "name": "uint", "nodeType": "ElementaryTypeName", "src": "1391:4:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 162, "name": "_to", "nodeType": "VariableDeclaration", "scope": 204, "src": "1408:11:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 161, "name": "address", "nodeType": "ElementaryTypeName", "src": "1408:7:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "value": null, "visibility": "internal" } ], "src": "1390:30:0" }, "payable": false, "returnParameters": { "id": 164, "nodeType": "ParameterList", "parameters": [], "src": "1428:0:0" }, "scope": 341, "src": "1366:350:0", "stateMutability": "nonpayable", "superFunction": null, "visibility": "public" }, { "body": { "id": 240, "nodeType": "Block", "src": "1838:159:0", "statements": [ { "assignments": [ 218 ], "declarations": [ { "constant": false, "id": 218, "name": "remoteContract", "nodeType": "VariableDeclaration", "scope": 241, "src": "1842:20:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_contract$_MyNFT_$451", "typeString": "contract MyNFT" }, "typeName": { "contractScope": null, "id": 217, "name": "MyNFT", "nodeType": "UserDefinedTypeName", "referencedDeclaration": 451, "src": "1842:5:0", "typeDescriptions": { "typeIdentifier": "t_contract$_MyNFT_$451", "typeString": "contract MyNFT" } }, "value": null, "visibility": "internal" } ], "id": 222, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "id": 220, "name": "_repoAddress", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 210, "src": "1871:12:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_address", "typeString": "address" } ], "id": 219, "name": "MyNFT", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 451, "src": "1865:5:0", "typeDescriptions": { "typeIdentifier": "t_type$_t_contract$_MyNFT_$451_$", "typeString": "type(contract MyNFT)" } }, "id": 221, "isConstant": false, "isLValue": false, "isPure": false, "kind": "typeConversion", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "1865:19:0", "typeDescriptions": { "typeIdentifier": "t_contract$_MyNFT_$451", "typeString": "contract MyNFT" } }, "nodeType": "VariableDeclarationStatement", "src": "1842:42:0" }, { "expression": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "id": 226, "name": "_to", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 208, "src": "1911:3:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, { "argumentTypes": null, "id": 227, "name": "_tokenId", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 212, "src": "1916:8:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_address", "typeString": "address" }, { "typeIdentifier": "t_uint256", "typeString": "uint256" } ], "expression": { "argumentTypes": null, "id": 223, "name": "remoteContract", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 218, "src": "1888:14:0", "typeDescriptions": { "typeIdentifier": "t_contract$_MyNFT_$451", "typeString": "contract MyNFT" } }, "id": 225, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "approve", "nodeType": "MemberAccess", "referencedDeclaration": 960, "src": "1888:22:0", "typeDescriptions": { "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$__$", "typeString": "function (address,uint256) external" } }, "id": 228, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "1888:37:0", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, "id": 229, "nodeType": "ExpressionStatement", "src": "1888:37:0" }, { "expression": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "id": 233, "name": "_from", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 206, "src": "1957:5:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, { "argumentTypes": null, "id": 234, "name": "_to", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 208, "src": "1964:3:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, { "argumentTypes": null, "id": 235, "name": "_tokenId", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 212, "src": "1969:8:0", "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": 230, "name": "remoteContract", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 218, "src": "1929:14:0", "typeDescriptions": { "typeIdentifier": "t_contract$_MyNFT_$451", "typeString": "contract MyNFT" } }, "id": 232, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "transferFrom", "nodeType": "MemberAccess", "referencedDeclaration": 1074, "src": "1929:27:0", "typeDescriptions": { "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", "typeString": "function (address,address,uint256) external" } }, "id": 236, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "1929:49:0", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, "id": 237, "nodeType": "ExpressionStatement", "src": "1929:49:0" }, { "expression": { "argumentTypes": null, "hexValue": "74727565", "id": 238, "isConstant": false, "isLValue": false, "isPure": true, "kind": "bool", "lValueRequested": false, "nodeType": "Literal", "src": "1989:4:0", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" }, "value": "true" }, "functionReturnParameters": 216, "id": 239, "nodeType": "Return", "src": "1982:11:0" } ] }, "documentation": null, "id": 241, "implemented": true, "isConstructor": false, "isDeclaredConst": false, "modifiers": [], "name": "approveAndTransfer", "nodeType": "FunctionDefinition", "parameters": { "id": 213, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 206, "name": "_from", "nodeType": "VariableDeclaration", "scope": 241, "src": "1747:13:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 205, "name": "address", "nodeType": "ElementaryTypeName", "src": "1747:7:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 208, "name": "_to", "nodeType": "VariableDeclaration", "scope": 241, "src": "1762:11:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 207, "name": "address", "nodeType": "ElementaryTypeName", "src": "1762:7:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 210, "name": "_repoAddress", "nodeType": "VariableDeclaration", "scope": 241, "src": "1775:20:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 209, "name": "address", "nodeType": "ElementaryTypeName", "src": "1775:7:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 212, "name": "_tokenId", "nodeType": "VariableDeclaration", "scope": 241, "src": "1797:16:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 211, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "1797:7:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "value": null, "visibility": "internal" } ], "src": "1746:68:0" }, "payable": false, "returnParameters": { "id": 216, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 215, "name": "", "nodeType": "VariableDeclaration", "scope": 241, "src": "1832:4:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" }, "typeName": { "id": 214, "name": "bool", "nodeType": "ElementaryTypeName", "src": "1832:4:0", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "value": null, "visibility": "internal" } ], "src": "1831:6:0" }, "scope": 341, "src": "1719:278:0", "stateMutability": "nonpayable", "superFunction": null, "visibility": "internal" }, { "body": { "id": 249, "nodeType": "Block", "src": "2053:30:0", "statements": [ { "expression": { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 246, "name": "auctions", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 5, "src": "2064:8:0", "typeDescriptions": { "typeIdentifier": "t_array$_t_struct$_Auction_$27_storage_$dyn_storage", "typeString": "struct Auctions.Auction storage ref[] storage ref" } }, "id": 247, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "memberName": "length", "nodeType": "MemberAccess", "referencedDeclaration": null, "src": "2064:15:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "functionReturnParameters": 245, "id": 248, "nodeType": "Return", "src": "2057:22:0" } ] }, "documentation": null, "id": 250, "implemented": true, "isConstructor": false, "isDeclaredConst": true, "modifiers": [], "name": "getCount", "nodeType": "FunctionDefinition", "parameters": { "id": 242, "nodeType": "ParameterList", "parameters": [], "src": "2020:2:0" }, "payable": false, "returnParameters": { "id": 245, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 244, "name": "", "nodeType": "VariableDeclaration", "scope": 250, "src": "2047:4:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 243, "name": "uint", "nodeType": "ElementaryTypeName", "src": "2047:4:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "value": null, "visibility": "internal" } ], "src": "2046:6:0" }, "scope": 341, "src": "2003:80:0", "stateMutability": "view", "superFunction": null, "visibility": "public" }, { "body": { "id": 268, "nodeType": "Block", "src": "2157:82:0", "statements": [ { "assignments": [ 261 ], "declarations": [ { "constant": false, "id": 261, "name": "ownedAuctions", "nodeType": "VariableDeclaration", "scope": 269, "src": "2161:27:0", "stateVariable": false, "storageLocation": "memory", "typeDescriptions": { "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr", "typeString": "uint256[]" }, "typeName": { "baseType": { "id": 259, "name": "uint", "nodeType": "ElementaryTypeName", "src": "2161:4:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "id": 260, "length": null, "nodeType": "ArrayTypeName", "src": "2161:6:0", "typeDescriptions": { "typeIdentifier": "t_array$_t_uint256_$dyn_storage_ptr", "typeString": "uint256[]" } }, "value": null, "visibility": "internal" } ], "id": 265, "initialValue": { "argumentTypes": null, "baseExpression": { "argumentTypes": null, "id": 262, "name": "auctionOwner", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 10, "src": "2191:12:0", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_array$_t_uint256_$dyn_storage_$", "typeString": "mapping(address => uint256[] storage ref)" } }, "id": 264, "indexExpression": { "argumentTypes": null, "id": 263, "name": "_owner", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 252, "src": "2204:6:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", "src": "2191:20:0", "typeDescriptions": { "typeIdentifier": "t_array$_t_uint256_$dyn_storage", "typeString": "uint256[] storage ref" } }, "nodeType": "VariableDeclarationStatement", "src": "2161:50:0" }, { "expression": { "argumentTypes": null, "id": 266, "name": "ownedAuctions", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 261, "src": "2222:13:0", "typeDescriptions": { "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr", "typeString": "uint256[] memory" } }, "functionReturnParameters": 257, "id": 267, "nodeType": "Return", "src": "2215:20:0" } ] }, "documentation": null, "id": 269, "implemented": true, "isConstructor": false, "isDeclaredConst": true, "modifiers": [], "name": "getAuctionsOf", "nodeType": "FunctionDefinition", "parameters": { "id": 253, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 252, "name": "_owner", "nodeType": "VariableDeclaration", "scope": 269, "src": "2109:14:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 251, "name": "address", "nodeType": "ElementaryTypeName", "src": "2109:7:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "value": null, "visibility": "internal" } ], "src": "2108:16:0" }, "payable": false, "returnParameters": { "id": 257, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 256, "name": "", "nodeType": "VariableDeclaration", "scope": 269, "src": "2149:6:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr", "typeString": "uint256[]" }, "typeName": { "baseType": { "id": 254, "name": "uint", "nodeType": "ElementaryTypeName", "src": "2149:4:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "id": 255, "length": null, "nodeType": "ArrayTypeName", "src": "2149:6:0", "typeDescriptions": { "typeIdentifier": "t_array$_t_uint256_$dyn_storage_ptr", "typeString": "uint256[]" } }, "value": null, "visibility": "internal" } ], "src": "2148:8:0" }, "scope": 341, "src": "2086:153:0", "stateMutability": "view", "superFunction": null, "visibility": "public" }, { "body": { "id": 281, "nodeType": "Block", "src": "2321:42:0", "statements": [ { "expression": { "argumentTypes": null, "expression": { "argumentTypes": null, "baseExpression": { "argumentTypes": null, "id": 276, "name": "auctionOwner", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 10, "src": "2332:12:0", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_array$_t_uint256_$dyn_storage_$", "typeString": "mapping(address => uint256[] storage ref)" } }, "id": 278, "indexExpression": { "argumentTypes": null, "id": 277, "name": "_owner", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 271, "src": "2345:6:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", "src": "2332:20:0", "typeDescriptions": { "typeIdentifier": "t_array$_t_uint256_$dyn_storage", "typeString": "uint256[] storage ref" } }, "id": 279, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "memberName": "length", "nodeType": "MemberAccess", "referencedDeclaration": null, "src": "2332:27:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "functionReturnParameters": 275, "id": 280, "nodeType": "Return", "src": "2325:34:0" } ] }, "documentation": null, "id": 282, "implemented": true, "isConstructor": false, "isDeclaredConst": true, "modifiers": [], "name": "getAuctionsCountOfOwner", "nodeType": "FunctionDefinition", "parameters": { "id": 272, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 271, "name": "_owner", "nodeType": "VariableDeclaration", "scope": 282, "src": "2275:14:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 270, "name": "address", "nodeType": "ElementaryTypeName", "src": "2275:7:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "value": null, "visibility": "internal" } ], "src": "2274:16:0" }, "payable": false, "returnParameters": { "id": 275, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 274, "name": "", "nodeType": "VariableDeclaration", "scope": 282, "src": "2315:4:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 273, "name": "uint", "nodeType": "ElementaryTypeName", "src": "2315:4:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "value": null, "visibility": "internal" } ], "src": "2314:6:0" }, "scope": 341, "src": "2242:121:0", "stateMutability": "view", "superFunction": null, "visibility": "public" }, { "body": { "id": 327, "nodeType": "Block", "src": "2575:188:0", "statements": [ { "assignments": [ 304 ], "declarations": [ { "constant": false, "id": 304, "name": "auc", "nodeType": "VariableDeclaration", "scope": 328, "src": "2579:18:0", "stateVariable": false, "storageLocation": "memory", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction" }, "typeName": { "contractScope": null, "id": 303, "name": "Auction", "nodeType": "UserDefinedTypeName", "referencedDeclaration": 27, "src": "2579:7:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_storage_ptr", "typeString": "struct Auctions.Auction" } }, "value": null, "visibility": "internal" } ], "id": 308, "initialValue": { "argumentTypes": null, "baseExpression": { "argumentTypes": null, "id": 305, "name": "auctions", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 5, "src": "2600:8:0", "typeDescriptions": { "typeIdentifier": "t_array$_t_struct$_Auction_$27_storage_$dyn_storage", "typeString": "struct Auctions.Auction storage ref[] storage ref" } }, "id": 307, "indexExpression": { "argumentTypes": null, "id": 306, "name": "_auctionId", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 284, "src": "2609:10:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", "src": "2600:20:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_storage", "typeString": "struct Auctions.Auction storage ref" } }, "nodeType": "VariableDeclarationStatement", "src": "2579:41:0" }, { "expression": { "argumentTypes": null, "components": [ { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 309, "name": "auc", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 304, "src": "2636:3:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction memory" } }, "id": 310, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "memberName": "name", "nodeType": "MemberAccess", "referencedDeclaration": 12, "src": "2636:8:0", "typeDescriptions": { "typeIdentifier": "t_string_memory", "typeString": "string memory" } }, { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 311, "name": "auc", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 304, "src": "2649:3:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction memory" } }, "id": 312, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "memberName": "price", "nodeType": "MemberAccess", "referencedDeclaration": 14, "src": "2649:9:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 313, "name": "auc", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 304, "src": "2663:3:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction memory" } }, "id": 314, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "memberName": "metadata", "nodeType": "MemberAccess", "referencedDeclaration": 16, "src": "2663:12:0", "typeDescriptions": { "typeIdentifier": "t_string_memory", "typeString": "string memory" } }, { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 315, "name": "auc", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 304, "src": "2680:3:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction memory" } }, "id": 316, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "memberName": "tokenId", "nodeType": "MemberAccess", "referencedDeclaration": 18, "src": "2680:11:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 317, "name": "auc", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 304, "src": "2696:3:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction memory" } }, "id": 318, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "memberName": "repoAddress", "nodeType": "MemberAccess", "referencedDeclaration": 20, "src": "2696:15:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 319, "name": "auc", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 304, "src": "2716:3:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction memory" } }, "id": 320, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "memberName": "owner", "nodeType": "MemberAccess", "referencedDeclaration": 22, "src": "2716:9:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 321, "name": "auc", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 304, "src": "2730:3:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction memory" } }, "id": 322, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "memberName": "active", "nodeType": "MemberAccess", "referencedDeclaration": 24, "src": "2730:10:0", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 323, "name": "auc", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 304, "src": "2745:3:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction memory" } }, "id": 324, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "memberName": "finalized", "nodeType": "MemberAccess", "referencedDeclaration": 26, "src": "2745:13:0", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } } ], "id": 325, "isConstant": false, "isInlineArray": false, "isLValue": false, "isPure": false, "lValueRequested": false, "nodeType": "TupleExpression", "src": "2631:128:0", "typeDescriptions": { "typeIdentifier": "t_tuple$_t_string_memory_$_t_uint256_$_t_string_memory_$_t_uint256_$_t_address_$_t_address_$_t_bool_$_t_bool_$", "typeString": "tuple(string memory,uint256,string memory,uint256,address,address,bool,bool)" } }, "functionReturnParameters": 302, "id": 326, "nodeType": "Return", "src": "2624:135:0" } ] }, "documentation": null, "id": 328, "implemented": true, "isConstructor": false, "isDeclaredConst": true, "modifiers": [], "name": "getAuctionById", "nodeType": "FunctionDefinition", "parameters": { "id": 285, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 284, "name": "_auctionId", "nodeType": "VariableDeclaration", "scope": 328, "src": "2390:15:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 283, "name": "uint", "nodeType": "ElementaryTypeName", "src": "2390:4:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "value": null, "visibility": "internal" } ], "src": "2389:17:0" }, "payable": false, "returnParameters": { "id": 302, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 287, "name": "name", "nodeType": "VariableDeclaration", "scope": 328, "src": "2434:11:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_string_memory_ptr", "typeString": "string" }, "typeName": { "id": 286, "name": "string", "nodeType": "ElementaryTypeName", "src": "2434:6:0", "typeDescriptions": { "typeIdentifier": "t_string_storage_ptr", "typeString": "string" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 289, "name": "price", "nodeType": "VariableDeclaration", "scope": 328, "src": "2449:13:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 288, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "2449:7:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 291, "name": "metadata", "nodeType": "VariableDeclaration", "scope": 328, "src": "2466:15:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_string_memory_ptr", "typeString": "string" }, "typeName": { "id": 290, "name": "string", "nodeType": "ElementaryTypeName", "src": "2466:6:0", "typeDescriptions": { "typeIdentifier": "t_string_storage_ptr", "typeString": "string" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 293, "name": "tokenId", "nodeType": "VariableDeclaration", "scope": 328, "src": "2485:15:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 292, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "2485:7:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 295, "name": "repoAddress", "nodeType": "VariableDeclaration", "scope": 328, "src": "2504:19:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 294, "name": "address", "nodeType": "ElementaryTypeName", "src": "2504:7:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 297, "name": "owner", "nodeType": "VariableDeclaration", "scope": 328, "src": "2527:13:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 296, "name": "address", "nodeType": "ElementaryTypeName", "src": "2527:7:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 299, "name": "active", "nodeType": "VariableDeclaration", "scope": 328, "src": "2544:11:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" }, "typeName": { "id": 298, "name": "bool", "nodeType": "ElementaryTypeName", "src": "2544:4:0", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 301, "name": "finalized", "nodeType": "VariableDeclaration", "scope": 328, "src": "2559:14:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" }, "typeName": { "id": 300, "name": "bool", "nodeType": "ElementaryTypeName", "src": "2559:4:0", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "value": null, "visibility": "internal" } ], "src": "2430:144:0" }, "scope": 341, "src": "2366:397:0", "stateMutability": "view", "superFunction": null, "visibility": "public" }, { "anonymous": false, "documentation": null, "id": 334, "name": "AuctionCreated", "nodeType": "EventDefinition", "parameters": { "id": 333, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 330, "indexed": false, "name": "_owner", "nodeType": "VariableDeclaration", "scope": 334, "src": "2787:14:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 329, "name": "address", "nodeType": "ElementaryTypeName", "src": "2787:7:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 332, "indexed": false, "name": "_auctionId", "nodeType": "VariableDeclaration", "scope": 334, "src": "2803:15:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 331, "name": "uint", "nodeType": "ElementaryTypeName", "src": "2803:4:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "value": null, "visibility": "internal" } ], "src": "2786:33:0" }, "src": "2766:54:0" }, { "anonymous": false, "documentation": null, "id": 340, "name": "AuctionFinalized", "nodeType": "EventDefinition", "parameters": { "id": 339, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 336, "indexed": false, "name": "_owner", "nodeType": "VariableDeclaration", "scope": 340, "src": "2845:14:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 335, "name": "address", "nodeType": "ElementaryTypeName", "src": "2845:7:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 338, "indexed": false, "name": "_auctionId", "nodeType": "VariableDeclaration", "scope": 340, "src": "2861:15:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 337, "name": "uint", "nodeType": "ElementaryTypeName", "src": "2861:4:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "value": null, "visibility": "internal" } ], "src": "2844:33:0" }, "src": "2822:56:0" } ], "scope": 342, "src": "49:2831:0" } ], "src": "0:2881:0" }, "legacyAST": { "absolutePath": "/Users/willpark/Desktop/bookwork-klaytn/project_codes/nftbapp/backend-nftdapp/contracts/Auctions.sol", "exportedSymbols": { "Auctions": [ 341 ] }, "id": 342, "nodeType": "SourceUnit", "nodes": [ { "id": 1, "literals": [ "solidity", "^", "0.4", ".24" ], "nodeType": "PragmaDirective", "src": "0:24:0" }, { "absolutePath": "/Users/willpark/Desktop/bookwork-klaytn/project_codes/nftbapp/backend-nftdapp/contracts/MyNFT.sol", "file": "./MyNFT.sol", "id": 2, "nodeType": "ImportDirective", "scope": 342, "sourceUnit": 452, "src": "26:21:0", "symbolAliases": [], "unitAlias": "" }, { "baseContracts": [], "contractDependencies": [], "contractKind": "contract", "documentation": null, "fullyImplemented": true, "id": 341, "linearizedBaseContracts": [ 341 ], "name": "Auctions", "nodeType": "ContractDefinition", "nodes": [ { "constant": false, "id": 5, "name": "auctions", "nodeType": "VariableDeclaration", "scope": 341, "src": "70:25:0", "stateVariable": true, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_array$_t_struct$_Auction_$27_storage_$dyn_storage", "typeString": "struct Auctions.Auction[]" }, "typeName": { "baseType": { "contractScope": null, "id": 3, "name": "Auction", "nodeType": "UserDefinedTypeName", "referencedDeclaration": 27, "src": "70:7:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_storage_ptr", "typeString": "struct Auctions.Auction" } }, "id": 4, "length": null, "nodeType": "ArrayTypeName", "src": "70:9:0", "typeDescriptions": { "typeIdentifier": "t_array$_t_struct$_Auction_$27_storage_$dyn_storage_ptr", "typeString": "struct Auctions.Auction[]" } }, "value": null, "visibility": "public" }, { "constant": false, "id": 10, "name": "auctionOwner", "nodeType": "VariableDeclaration", "scope": 341, "src": "99:46:0", "stateVariable": true, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_array$_t_uint256_$dyn_storage_$", "typeString": "mapping(address => uint256[])" }, "typeName": { "id": 9, "keyType": { "id": 6, "name": "address", "nodeType": "ElementaryTypeName", "src": "107:7:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "nodeType": "Mapping", "src": "99:26:0", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_array$_t_uint256_$dyn_storage_$", "typeString": "mapping(address => uint256[])" }, "valueType": { "baseType": { "id": 7, "name": "uint", "nodeType": "ElementaryTypeName", "src": "118:4:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "id": 8, "length": null, "nodeType": "ArrayTypeName", "src": "118:6:0", "typeDescriptions": { "typeIdentifier": "t_array$_t_uint256_$dyn_storage_ptr", "typeString": "uint256[]" } } }, "value": null, "visibility": "public" }, { "canonicalName": "Auctions.Auction", "id": 27, "members": [ { "constant": false, "id": 12, "name": "name", "nodeType": "VariableDeclaration", "scope": 27, "src": "169:11:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_string_storage_ptr", "typeString": "string" }, "typeName": { "id": 11, "name": "string", "nodeType": "ElementaryTypeName", "src": "169:6:0", "typeDescriptions": { "typeIdentifier": "t_string_storage_ptr", "typeString": "string" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 14, "name": "price", "nodeType": "VariableDeclaration", "scope": 27, "src": "195:13:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 13, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "195:7:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 16, "name": "metadata", "nodeType": "VariableDeclaration", "scope": 27, "src": "223:15:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_string_storage_ptr", "typeString": "string" }, "typeName": { "id": 15, "name": "string", "nodeType": "ElementaryTypeName", "src": "223:6:0", "typeDescriptions": { "typeIdentifier": "t_string_storage_ptr", "typeString": "string" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 18, "name": "tokenId", "nodeType": "VariableDeclaration", "scope": 27, "src": "274:15:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 17, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "274:7:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 20, "name": "repoAddress", "nodeType": "VariableDeclaration", "scope": 27, "src": "314:19:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 19, "name": "address", "nodeType": "ElementaryTypeName", "src": "314:7:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 22, "name": "owner", "nodeType": "VariableDeclaration", "scope": 27, "src": "371:13:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 21, "name": "address", "nodeType": "ElementaryTypeName", "src": "371:7:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 24, "name": "active", "nodeType": "VariableDeclaration", "scope": 27, "src": "406:11:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" }, "typeName": { "id": 23, "name": "bool", "nodeType": "ElementaryTypeName", "src": "406:4:0", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 26, "name": "finalized", "nodeType": "VariableDeclaration", "scope": 27, "src": "441:14:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" }, "typeName": { "id": 25, "name": "bool", "nodeType": "ElementaryTypeName", "src": "441:4:0", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "value": null, "visibility": "internal" } ], "name": "Auction", "nodeType": "StructDefinition", "scope": 341, "src": "149:332:0", "visibility": "public" }, { "body": { "id": 33, "nodeType": "Block", "src": "502:17:0", "statements": [ { "expression": { "argumentTypes": null, "arguments": [], "expression": { "argumentTypes": [], "id": 30, "name": "revert", "nodeType": "Identifier", "overloadedDeclarations": [ 1761, 1762 ], "referencedDeclaration": 1761, "src": "507:6:0", "typeDescriptions": { "typeIdentifier": "t_function_revert_pure$__$returns$__$", "typeString": "function () pure" } }, "id": 31, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "507:8:0", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, "id": 32, "nodeType": "ExpressionStatement", "src": "507:8:0" } ] }, "documentation": null, "id": 34, "implemented": true, "isConstructor": false, "isDeclaredConst": false, "modifiers": [], "name": "", "nodeType": "FunctionDefinition", "parameters": { "id": 28, "nodeType": "ParameterList", "parameters": [], "src": "492:2:0" }, "payable": false, "returnParameters": { "id": 29, "nodeType": "ParameterList", "parameters": [], "src": "502:0:0" }, "scope": 341, "src": "484:35:0", "stateMutability": "nonpayable", "superFunction": null, "visibility": "public" }, { "body": { "id": 58, "nodeType": "Block", "src": "590:110:0", "statements": [ { "assignments": [ 41 ], "declarations": [ { "constant": false, "id": 41, "name": "nftOwner", "nodeType": "VariableDeclaration", "scope": 59, "src": "595:16:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 40, "name": "address", "nodeType": "ElementaryTypeName", "src": "595:7:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "value": null, "visibility": "internal" } ], "id": 48, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "id": 46, "name": "_tokenId", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 38, "src": "642:8:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_uint256", "typeString": "uint256" } ], "expression": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "id": 43, "name": "_repoAddress", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 36, "src": "620:12:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_address", "typeString": "address" } ], "id": 42, "name": "MyNFT", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 451, "src": "614:5:0", "typeDescriptions": { "typeIdentifier": "t_type$_t_contract$_MyNFT_$451_$", "typeString": "type(contract MyNFT)" } }, "id": 44, "isConstant": false, "isLValue": false, "isPure": false, "kind": "typeConversion", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "614:19:0", "typeDescriptions": { "typeIdentifier": "t_contract$_MyNFT_$451", "typeString": "contract MyNFT" } }, "id": 45, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "ownerOf", "nodeType": "MemberAccess", "referencedDeclaration": 895, "src": "614:27:0", "typeDescriptions": { "typeIdentifier": "t_function_external_view$_t_uint256_$returns$_t_address_$", "typeString": "function (uint256) view external returns (address)" } }, "id": 47, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "614:37:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "nodeType": "VariableDeclarationStatement", "src": "595:56:0" }, { "expression": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "commonType": { "typeIdentifier": "t_address", "typeString": "address" }, "id": 54, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "argumentTypes": null, "id": 50, "name": "nftOwner", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 41, "src": "664:8:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "nodeType": "BinaryOperation", "operator": "==", "rightExpression": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "id": 52, "name": "this", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 1793, "src": "684:4:0", "typeDescriptions": { "typeIdentifier": "t_contract$_Auctions_$341", "typeString": "contract Auctions" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_contract$_Auctions_$341", "typeString": "contract Auctions" } ], "id": 51, "isConstant": false, "isLValue": false, "isPure": true, "lValueRequested": false, "nodeType": "ElementaryTypeNameExpression", "src": "676:7:0", "typeDescriptions": { "typeIdentifier": "t_type$_t_address_$", "typeString": "type(address)" }, "typeName": "address" }, "id": 53, "isConstant": false, "isLValue": false, "isPure": false, "kind": "typeConversion", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "676:13:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "src": "664:25:0", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_bool", "typeString": "bool" } ], "id": 49, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ 1759, 1760 ], "referencedDeclaration": 1759, "src": "656:7:0", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$", "typeString": "function (bool) pure" } }, "id": 55, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "656:34:0", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, "id": 56, "nodeType": "ExpressionStatement", "src": "656:34:0" }, { "id": 57, "nodeType": "PlaceholderStatement", "src": "695:1:0" } ] }, "documentation": null, "id": 59, "name": "contractIsNFTOwner", "nodeType": "ModifierDefinition", "parameters": { "id": 39, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 36, "name": "_repoAddress", "nodeType": "VariableDeclaration", "scope": 59, "src": "550:20:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 35, "name": "address", "nodeType": "ElementaryTypeName", "src": "550:7:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 38, "name": "_tokenId", "nodeType": "VariableDeclaration", "scope": 59, "src": "572:16:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 37, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "572:7:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "value": null, "visibility": "internal" } ], "src": "549:40:0" }, "src": "522:178:0", "visibility": "internal" }, { "body": { "id": 157, "nodeType": "Block", "src": "886:477:0", "statements": [ { "assignments": [ 79 ], "declarations": [ { "constant": false, "id": 79, "name": "auctionId", "nodeType": "VariableDeclaration", "scope": 158, "src": "890:14:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 78, "name": "uint", "nodeType": "ElementaryTypeName", "src": "890:4:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "value": null, "visibility": "internal" } ], "id": 82, "initialValue": { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 80, "name": "auctions", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 5, "src": "907:8:0", "typeDescriptions": { "typeIdentifier": "t_array$_t_struct$_Auction_$27_storage_$dyn_storage", "typeString": "struct Auctions.Auction storage ref[] storage ref" } }, "id": 81, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "memberName": "length", "nodeType": "MemberAccess", "referencedDeclaration": null, "src": "907:15:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "VariableDeclarationStatement", "src": "890:32:0" }, { "assignments": [], "declarations": [ { "constant": false, "id": 84, "name": "newAuction", "nodeType": "VariableDeclaration", "scope": 158, "src": "926:25:0", "stateVariable": false, "storageLocation": "memory", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction" }, "typeName": { "contractScope": null, "id": 83, "name": "Auction", "nodeType": "UserDefinedTypeName", "referencedDeclaration": 27, "src": "926:7:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_storage_ptr", "typeString": "struct Auctions.Auction" } }, "value": null, "visibility": "internal" } ], "id": 85, "initialValue": null, "nodeType": "VariableDeclarationStatement", "src": "926:25:0" }, { "expression": { "argumentTypes": null, "id": 90, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 86, "name": "newAuction", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 84, "src": "955:10:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction memory" } }, "id": 88, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": true, "memberName": "name", "nodeType": "MemberAccess", "referencedDeclaration": 12, "src": "955:15:0", "typeDescriptions": { "typeIdentifier": "t_string_memory", "typeString": "string memory" } }, "nodeType": "Assignment", "operator": "=", "rightHandSide": { "argumentTypes": null, "id": 89, "name": "_auctionTitle", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 65, "src": "973:13:0", "typeDescriptions": { "typeIdentifier": "t_string_memory_ptr", "typeString": "string memory" } }, "src": "955:31:0", "typeDescriptions": { "typeIdentifier": "t_string_memory", "typeString": "string memory" } }, "id": 91, "nodeType": "ExpressionStatement", "src": "955:31:0" }, { "expression": { "argumentTypes": null, "id": 96, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 92, "name": "newAuction", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 84, "src": "990:10:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction memory" } }, "id": 94, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": true, "memberName": "price", "nodeType": "MemberAccess", "referencedDeclaration": 14, "src": "990:16:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "Assignment", "operator": "=", "rightHandSide": { "argumentTypes": null, "id": 95, "name": "_price", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 69, "src": "1009:6:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "src": "990:25:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "id": 97, "nodeType": "ExpressionStatement", "src": "990:25:0" }, { "expression": { "argumentTypes": null, "id": 102, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 98, "name": "newAuction", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 84, "src": "1019:10:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction memory" } }, "id": 100, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": true, "memberName": "metadata", "nodeType": "MemberAccess", "referencedDeclaration": 16, "src": "1019:19:0", "typeDescriptions": { "typeIdentifier": "t_string_memory", "typeString": "string memory" } }, "nodeType": "Assignment", "operator": "=", "rightHandSide": { "argumentTypes": null, "id": 101, "name": "_metadata", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 67, "src": "1041:9:0", "typeDescriptions": { "typeIdentifier": "t_string_memory_ptr", "typeString": "string memory" } }, "src": "1019:31:0", "typeDescriptions": { "typeIdentifier": "t_string_memory", "typeString": "string memory" } }, "id": 103, "nodeType": "ExpressionStatement", "src": "1019:31:0" }, { "expression": { "argumentTypes": null, "id": 108, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 104, "name": "newAuction", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 84, "src": "1054:10:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction memory" } }, "id": 106, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": true, "memberName": "tokenId", "nodeType": "MemberAccess", "referencedDeclaration": 18, "src": "1054:18:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "Assignment", "operator": "=", "rightHandSide": { "argumentTypes": null, "id": 107, "name": "_tokenId", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 63, "src": "1075:8:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "src": "1054:29:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "id": 109, "nodeType": "ExpressionStatement", "src": "1054:29:0" }, { "expression": { "argumentTypes": null, "id": 114, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 110, "name": "newAuction", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 84, "src": "1087:10:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction memory" } }, "id": 112, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": true, "memberName": "repoAddress", "nodeType": "MemberAccess", "referencedDeclaration": 20, "src": "1087:22:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "nodeType": "Assignment", "operator": "=", "rightHandSide": { "argumentTypes": null, "id": 113, "name": "_repoAddress", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 61, "src": "1112:12:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "src": "1087:37:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "id": 115, "nodeType": "ExpressionStatement", "src": "1087:37:0" }, { "expression": { "argumentTypes": null, "id": 121, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 116, "name": "newAuction", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 84, "src": "1128:10:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction memory" } }, "id": 118, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": true, "memberName": "owner", "nodeType": "MemberAccess", "referencedDeclaration": 22, "src": "1128:16:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "nodeType": "Assignment", "operator": "=", "rightHandSide": { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 119, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 1756, "src": "1147:3:0", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, "id": 120, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, "src": "1147:10:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "src": "1128:29:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "id": 122, "nodeType": "ExpressionStatement", "src": "1128:29:0" }, { "expression": { "argumentTypes": null, "id": 127, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 123, "name": "newAuction", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 84, "src": "1161:10:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction memory" } }, "id": 125, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": true, "memberName": "active", "nodeType": "MemberAccess", "referencedDeclaration": 24, "src": "1161:17:0", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "nodeType": "Assignment", "operator": "=", "rightHandSide": { "argumentTypes": null, "hexValue": "74727565", "id": 126, "isConstant": false, "isLValue": false, "isPure": true, "kind": "bool", "lValueRequested": false, "nodeType": "Literal", "src": "1181:4:0", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" }, "value": "true" }, "src": "1161:24:0", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "id": 128, "nodeType": "ExpressionStatement", "src": "1161:24:0" }, { "expression": { "argumentTypes": null, "id": 133, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 129, "name": "newAuction", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 84, "src": "1195:10:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction memory" } }, "id": 131, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": true, "memberName": "finalized", "nodeType": "MemberAccess", "referencedDeclaration": 26, "src": "1195:20:0", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "nodeType": "Assignment", "operator": "=", "rightHandSide": { "argumentTypes": null, "hexValue": "66616c7365", "id": 132, "isConstant": false, "isLValue": false, "isPure": true, "kind": "bool", "lValueRequested": false, "nodeType": "Literal", "src": "1218:5:0", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" }, "value": "false" }, "src": "1195:28:0", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "id": 134, "nodeType": "ExpressionStatement", "src": "1195:28:0" }, { "expression": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "id": 138, "name": "newAuction", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 84, "src": "1242:10:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction memory" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction memory" } ], "expression": { "argumentTypes": null, "id": 135, "name": "auctions", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 5, "src": "1228:8:0", "typeDescriptions": { "typeIdentifier": "t_array$_t_struct$_Auction_$27_storage_$dyn_storage", "typeString": "struct Auctions.Auction storage ref[] storage ref" } }, "id": 137, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "push", "nodeType": "MemberAccess", "referencedDeclaration": null, "src": "1228:13:0", "typeDescriptions": { "typeIdentifier": "t_function_arraypush_nonpayable$_t_struct$_Auction_$27_storage_$returns$_t_uint256_$", "typeString": "function (struct Auctions.Auction storage ref) returns (uint256)" } }, "id": 139, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "1228:25:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "id": 140, "nodeType": "ExpressionStatement", "src": "1228:25:0" }, { "expression": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "id": 146, "name": "auctionId", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 79, "src": "1287:9:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_uint256", "typeString": "uint256" } ], "expression": { "argumentTypes": null, "baseExpression": { "argumentTypes": null, "id": 141, "name": "auctionOwner", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 10, "src": "1257:12:0", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_array$_t_uint256_$dyn_storage_$", "typeString": "mapping(address => uint256[] storage ref)" } }, "id": 144, "indexExpression": { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 142, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 1756, "src": "1270:3:0", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, "id": 143, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, "src": "1270:10:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", "src": "1257:24:0", "typeDescriptions": { "typeIdentifier": "t_array$_t_uint256_$dyn_storage", "typeString": "uint256[] storage ref" } }, "id": 145, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "push", "nodeType": "MemberAccess", "referencedDeclaration": null, "src": "1257:29:0", "typeDescriptions": { "typeIdentifier": "t_function_arraypush_nonpayable$_t_uint256_$returns$_t_uint256_$", "typeString": "function (uint256) returns (uint256)" } }, "id": 147, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "1257:40:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "id": 148, "nodeType": "ExpressionStatement", "src": "1257:40:0" }, { "eventCall": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 150, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 1756, "src": "1322:3:0", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, "id": 151, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, "src": "1322:10:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, { "argumentTypes": null, "id": 152, "name": "auctionId", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 79, "src": "1334:9:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_address", "typeString": "address" }, { "typeIdentifier": "t_uint256", "typeString": "uint256" } ], "id": 149, "name": "AuctionCreated", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 334, "src": "1307:14:0", "typeDescriptions": { "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$returns$__$", "typeString": "function (address,uint256)" } }, "id": 153, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "1307:37:0", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, "id": 154, "nodeType": "EmitStatement", "src": "1302:42:0" }, { "expression": { "argumentTypes": null, "hexValue": "74727565", "id": 155, "isConstant": false, "isLValue": false, "isPure": true, "kind": "bool", "lValueRequested": false, "nodeType": "Literal", "src": "1355:4:0", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" }, "value": "true" }, "functionReturnParameters": 77, "id": 156, "nodeType": "Return", "src": "1348:11:0" } ] }, "documentation": null, "id": 158, "implemented": true, "isConstructor": false, "isDeclaredConst": false, "modifiers": [ { "arguments": [ { "argumentTypes": null, "id": 72, "name": "_repoAddress", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 61, "src": "848:12:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, { "argumentTypes": null, "id": 73, "name": "_tokenId", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 63, "src": "862:8:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } } ], "id": 74, "modifierName": { "argumentTypes": null, "id": 71, "name": "contractIsNFTOwner", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 59, "src": "829:18:0", "typeDescriptions": { "typeIdentifier": "t_modifier$_t_address_$_t_uint256_$", "typeString": "modifier (address,uint256)" } }, "nodeType": "ModifierInvocation", "src": "829:42:0" } ], "name": "createAuction", "nodeType": "FunctionDefinition", "parameters": { "id": 70, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 61, "name": "_repoAddress", "nodeType": "VariableDeclaration", "scope": 158, "src": "726:20:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 60, "name": "address", "nodeType": "ElementaryTypeName", "src": "726:7:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 63, "name": "_tokenId", "nodeType": "VariableDeclaration", "scope": 158, "src": "748:16:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 62, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "748:7:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 65, "name": "_auctionTitle", "nodeType": "VariableDeclaration", "scope": 158, "src": "766:20:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_string_memory_ptr", "typeString": "string" }, "typeName": { "id": 64, "name": "string", "nodeType": "ElementaryTypeName", "src": "766:6:0", "typeDescriptions": { "typeIdentifier": "t_string_storage_ptr", "typeString": "string" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 67, "name": "_metadata", "nodeType": "VariableDeclaration", "scope": 158, "src": "788:16:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_string_memory_ptr", "typeString": "string" }, "typeName": { "id": 66, "name": "string", "nodeType": "ElementaryTypeName", "src": "788:6:0", "typeDescriptions": { "typeIdentifier": "t_string_storage_ptr", "typeString": "string" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 69, "name": "_price", "nodeType": "VariableDeclaration", "scope": 158, "src": "806:14:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 68, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "806:7:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "value": null, "visibility": "internal" } ], "src": "725:96:0" }, "payable": false, "returnParameters": { "id": 77, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 76, "name": "", "nodeType": "VariableDeclaration", "scope": 158, "src": "880:4:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" }, "typeName": { "id": 75, "name": "bool", "nodeType": "ElementaryTypeName", "src": "880:4:0", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "value": null, "visibility": "internal" } ], "src": "879:6:0" }, "scope": 341, "src": "703:660:0", "stateMutability": "nonpayable", "superFunction": null, "visibility": "public" }, { "body": { "id": 203, "nodeType": "Block", "src": "1428:288:0", "statements": [ { "assignments": [ 166 ], "declarations": [ { "constant": false, "id": 166, "name": "myAuction", "nodeType": "VariableDeclaration", "scope": 204, "src": "1432:24:0", "stateVariable": false, "storageLocation": "memory", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction" }, "typeName": { "contractScope": null, "id": 165, "name": "Auction", "nodeType": "UserDefinedTypeName", "referencedDeclaration": 27, "src": "1432:7:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_storage_ptr", "typeString": "struct Auctions.Auction" } }, "value": null, "visibility": "internal" } ], "id": 170, "initialValue": { "argumentTypes": null, "baseExpression": { "argumentTypes": null, "id": 167, "name": "auctions", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 5, "src": "1459:8:0", "typeDescriptions": { "typeIdentifier": "t_array$_t_struct$_Auction_$27_storage_$dyn_storage", "typeString": "struct Auctions.Auction storage ref[] storage ref" } }, "id": 169, "indexExpression": { "argumentTypes": null, "id": 168, "name": "_auctionId", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 160, "src": "1468:10:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", "src": "1459:20:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_storage", "typeString": "struct Auctions.Auction storage ref" } }, "nodeType": "VariableDeclarationStatement", "src": "1432:47:0" }, { "condition": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "id": 173, "name": "this", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 1793, "src": "1513:4:0", "typeDescriptions": { "typeIdentifier": "t_contract$_Auctions_$341", "typeString": "contract Auctions" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_contract$_Auctions_$341", "typeString": "contract Auctions" } ], "id": 172, "isConstant": false, "isLValue": false, "isPure": true, "lValueRequested": false, "nodeType": "ElementaryTypeNameExpression", "src": "1505:7:0", "typeDescriptions": { "typeIdentifier": "t_type$_t_address_$", "typeString": "type(address)" }, "typeName": "address" }, "id": 174, "isConstant": false, "isLValue": false, "isPure": false, "kind": "typeConversion", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "1505:13:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, { "argumentTypes": null, "id": 175, "name": "_to", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 162, "src": "1520:3:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 176, "name": "myAuction", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 166, "src": "1525:9:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction memory" } }, "id": 177, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "memberName": "repoAddress", "nodeType": "MemberAccess", "referencedDeclaration": 20, "src": "1525:21:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 178, "name": "myAuction", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 166, "src": "1548:9:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction memory" } }, "id": 179, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "memberName": "tokenId", "nodeType": "MemberAccess", "referencedDeclaration": 18, "src": "1548:17:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_address", "typeString": "address" }, { "typeIdentifier": "t_address", "typeString": "address" }, { "typeIdentifier": "t_address", "typeString": "address" }, { "typeIdentifier": "t_uint256", "typeString": "uint256" } ], "id": 171, "name": "approveAndTransfer", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 241, "src": "1486:18:0", "typeDescriptions": { "typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_address_$_t_address_$_t_uint256_$returns$_t_bool_$", "typeString": "function (address,address,address,uint256) returns (bool)" } }, "id": 180, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "1486:80:0", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "falseBody": null, "id": 202, "nodeType": "IfStatement", "src": "1483:230:0", "trueBody": { "id": 201, "nodeType": "Block", "src": "1567:146:0", "statements": [ { "expression": { "argumentTypes": null, "id": 186, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, "expression": { "argumentTypes": null, "baseExpression": { "argumentTypes": null, "id": 181, "name": "auctions", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 5, "src": "1575:8:0", "typeDescriptions": { "typeIdentifier": "t_array$_t_struct$_Auction_$27_storage_$dyn_storage", "typeString": "struct Auctions.Auction storage ref[] storage ref" } }, "id": 183, "indexExpression": { "argumentTypes": null, "id": 182, "name": "_auctionId", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 160, "src": "1584:10:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", "src": "1575:20:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_storage", "typeString": "struct Auctions.Auction storage ref" } }, "id": 184, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": true, "memberName": "active", "nodeType": "MemberAccess", "referencedDeclaration": 24, "src": "1575:27:0", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "nodeType": "Assignment", "operator": "=", "rightHandSide": { "argumentTypes": null, "hexValue": "66616c7365", "id": 185, "isConstant": false, "isLValue": false, "isPure": true, "kind": "bool", "lValueRequested": false, "nodeType": "Literal", "src": "1605:5:0", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" }, "value": "false" }, "src": "1575:35:0", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "id": 187, "nodeType": "ExpressionStatement", "src": "1575:35:0" }, { "expression": { "argumentTypes": null, "id": 193, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, "expression": { "argumentTypes": null, "baseExpression": { "argumentTypes": null, "id": 188, "name": "auctions", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 5, "src": "1618:8:0", "typeDescriptions": { "typeIdentifier": "t_array$_t_struct$_Auction_$27_storage_$dyn_storage", "typeString": "struct Auctions.Auction storage ref[] storage ref" } }, "id": 190, "indexExpression": { "argumentTypes": null, "id": 189, "name": "_auctionId", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 160, "src": "1627:10:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", "src": "1618:20:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_storage", "typeString": "struct Auctions.Auction storage ref" } }, "id": 191, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": true, "memberName": "finalized", "nodeType": "MemberAccess", "referencedDeclaration": 26, "src": "1618:30:0", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "nodeType": "Assignment", "operator": "=", "rightHandSide": { "argumentTypes": null, "hexValue": "74727565", "id": 192, "isConstant": false, "isLValue": false, "isPure": true, "kind": "bool", "lValueRequested": false, "nodeType": "Literal", "src": "1651:4:0", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" }, "value": "true" }, "src": "1618:37:0", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "id": 194, "nodeType": "ExpressionStatement", "src": "1618:37:0" }, { "eventCall": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 196, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 1756, "src": "1685:3:0", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, "id": 197, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, "src": "1685:10:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, { "argumentTypes": null, "id": 198, "name": "_auctionId", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 160, "src": "1697:10:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_address", "typeString": "address" }, { "typeIdentifier": "t_uint256", "typeString": "uint256" } ], "id": 195, "name": "AuctionFinalized", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 340, "src": "1668:16:0", "typeDescriptions": { "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$returns$__$", "typeString": "function (address,uint256)" } }, "id": 199, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "1668:40:0", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, "id": 200, "nodeType": "EmitStatement", "src": "1663:45:0" } ] } } ] }, "documentation": null, "id": 204, "implemented": true, "isConstructor": false, "isDeclaredConst": false, "modifiers": [], "name": "finalizeAuction", "nodeType": "FunctionDefinition", "parameters": { "id": 163, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 160, "name": "_auctionId", "nodeType": "VariableDeclaration", "scope": 204, "src": "1391:15:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 159, "name": "uint", "nodeType": "ElementaryTypeName", "src": "1391:4:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 162, "name": "_to", "nodeType": "VariableDeclaration", "scope": 204, "src": "1408:11:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 161, "name": "address", "nodeType": "ElementaryTypeName", "src": "1408:7:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "value": null, "visibility": "internal" } ], "src": "1390:30:0" }, "payable": false, "returnParameters": { "id": 164, "nodeType": "ParameterList", "parameters": [], "src": "1428:0:0" }, "scope": 341, "src": "1366:350:0", "stateMutability": "nonpayable", "superFunction": null, "visibility": "public" }, { "body": { "id": 240, "nodeType": "Block", "src": "1838:159:0", "statements": [ { "assignments": [ 218 ], "declarations": [ { "constant": false, "id": 218, "name": "remoteContract", "nodeType": "VariableDeclaration", "scope": 241, "src": "1842:20:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_contract$_MyNFT_$451", "typeString": "contract MyNFT" }, "typeName": { "contractScope": null, "id": 217, "name": "MyNFT", "nodeType": "UserDefinedTypeName", "referencedDeclaration": 451, "src": "1842:5:0", "typeDescriptions": { "typeIdentifier": "t_contract$_MyNFT_$451", "typeString": "contract MyNFT" } }, "value": null, "visibility": "internal" } ], "id": 222, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "id": 220, "name": "_repoAddress", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 210, "src": "1871:12:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_address", "typeString": "address" } ], "id": 219, "name": "MyNFT", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 451, "src": "1865:5:0", "typeDescriptions": { "typeIdentifier": "t_type$_t_contract$_MyNFT_$451_$", "typeString": "type(contract MyNFT)" } }, "id": 221, "isConstant": false, "isLValue": false, "isPure": false, "kind": "typeConversion", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "1865:19:0", "typeDescriptions": { "typeIdentifier": "t_contract$_MyNFT_$451", "typeString": "contract MyNFT" } }, "nodeType": "VariableDeclarationStatement", "src": "1842:42:0" }, { "expression": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "id": 226, "name": "_to", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 208, "src": "1911:3:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, { "argumentTypes": null, "id": 227, "name": "_tokenId", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 212, "src": "1916:8:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_address", "typeString": "address" }, { "typeIdentifier": "t_uint256", "typeString": "uint256" } ], "expression": { "argumentTypes": null, "id": 223, "name": "remoteContract", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 218, "src": "1888:14:0", "typeDescriptions": { "typeIdentifier": "t_contract$_MyNFT_$451", "typeString": "contract MyNFT" } }, "id": 225, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "approve", "nodeType": "MemberAccess", "referencedDeclaration": 960, "src": "1888:22:0", "typeDescriptions": { "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$__$", "typeString": "function (address,uint256) external" } }, "id": 228, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "1888:37:0", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, "id": 229, "nodeType": "ExpressionStatement", "src": "1888:37:0" }, { "expression": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "id": 233, "name": "_from", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 206, "src": "1957:5:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, { "argumentTypes": null, "id": 234, "name": "_to", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 208, "src": "1964:3:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, { "argumentTypes": null, "id": 235, "name": "_tokenId", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 212, "src": "1969:8:0", "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": 230, "name": "remoteContract", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 218, "src": "1929:14:0", "typeDescriptions": { "typeIdentifier": "t_contract$_MyNFT_$451", "typeString": "contract MyNFT" } }, "id": 232, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "transferFrom", "nodeType": "MemberAccess", "referencedDeclaration": 1074, "src": "1929:27:0", "typeDescriptions": { "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", "typeString": "function (address,address,uint256) external" } }, "id": 236, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "1929:49:0", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, "id": 237, "nodeType": "ExpressionStatement", "src": "1929:49:0" }, { "expression": { "argumentTypes": null, "hexValue": "74727565", "id": 238, "isConstant": false, "isLValue": false, "isPure": true, "kind": "bool", "lValueRequested": false, "nodeType": "Literal", "src": "1989:4:0", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" }, "value": "true" }, "functionReturnParameters": 216, "id": 239, "nodeType": "Return", "src": "1982:11:0" } ] }, "documentation": null, "id": 241, "implemented": true, "isConstructor": false, "isDeclaredConst": false, "modifiers": [], "name": "approveAndTransfer", "nodeType": "FunctionDefinition", "parameters": { "id": 213, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 206, "name": "_from", "nodeType": "VariableDeclaration", "scope": 241, "src": "1747:13:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 205, "name": "address", "nodeType": "ElementaryTypeName", "src": "1747:7:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 208, "name": "_to", "nodeType": "VariableDeclaration", "scope": 241, "src": "1762:11:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 207, "name": "address", "nodeType": "ElementaryTypeName", "src": "1762:7:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 210, "name": "_repoAddress", "nodeType": "VariableDeclaration", "scope": 241, "src": "1775:20:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 209, "name": "address", "nodeType": "ElementaryTypeName", "src": "1775:7:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 212, "name": "_tokenId", "nodeType": "VariableDeclaration", "scope": 241, "src": "1797:16:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 211, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "1797:7:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "value": null, "visibility": "internal" } ], "src": "1746:68:0" }, "payable": false, "returnParameters": { "id": 216, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 215, "name": "", "nodeType": "VariableDeclaration", "scope": 241, "src": "1832:4:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" }, "typeName": { "id": 214, "name": "bool", "nodeType": "ElementaryTypeName", "src": "1832:4:0", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "value": null, "visibility": "internal" } ], "src": "1831:6:0" }, "scope": 341, "src": "1719:278:0", "stateMutability": "nonpayable", "superFunction": null, "visibility": "internal" }, { "body": { "id": 249, "nodeType": "Block", "src": "2053:30:0", "statements": [ { "expression": { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 246, "name": "auctions", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 5, "src": "2064:8:0", "typeDescriptions": { "typeIdentifier": "t_array$_t_struct$_Auction_$27_storage_$dyn_storage", "typeString": "struct Auctions.Auction storage ref[] storage ref" } }, "id": 247, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "memberName": "length", "nodeType": "MemberAccess", "referencedDeclaration": null, "src": "2064:15:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "functionReturnParameters": 245, "id": 248, "nodeType": "Return", "src": "2057:22:0" } ] }, "documentation": null, "id": 250, "implemented": true, "isConstructor": false, "isDeclaredConst": true, "modifiers": [], "name": "getCount", "nodeType": "FunctionDefinition", "parameters": { "id": 242, "nodeType": "ParameterList", "parameters": [], "src": "2020:2:0" }, "payable": false, "returnParameters": { "id": 245, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 244, "name": "", "nodeType": "VariableDeclaration", "scope": 250, "src": "2047:4:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 243, "name": "uint", "nodeType": "ElementaryTypeName", "src": "2047:4:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "value": null, "visibility": "internal" } ], "src": "2046:6:0" }, "scope": 341, "src": "2003:80:0", "stateMutability": "view", "superFunction": null, "visibility": "public" }, { "body": { "id": 268, "nodeType": "Block", "src": "2157:82:0", "statements": [ { "assignments": [ 261 ], "declarations": [ { "constant": false, "id": 261, "name": "ownedAuctions", "nodeType": "VariableDeclaration", "scope": 269, "src": "2161:27:0", "stateVariable": false, "storageLocation": "memory", "typeDescriptions": { "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr", "typeString": "uint256[]" }, "typeName": { "baseType": { "id": 259, "name": "uint", "nodeType": "ElementaryTypeName", "src": "2161:4:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "id": 260, "length": null, "nodeType": "ArrayTypeName", "src": "2161:6:0", "typeDescriptions": { "typeIdentifier": "t_array$_t_uint256_$dyn_storage_ptr", "typeString": "uint256[]" } }, "value": null, "visibility": "internal" } ], "id": 265, "initialValue": { "argumentTypes": null, "baseExpression": { "argumentTypes": null, "id": 262, "name": "auctionOwner", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 10, "src": "2191:12:0", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_array$_t_uint256_$dyn_storage_$", "typeString": "mapping(address => uint256[] storage ref)" } }, "id": 264, "indexExpression": { "argumentTypes": null, "id": 263, "name": "_owner", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 252, "src": "2204:6:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", "src": "2191:20:0", "typeDescriptions": { "typeIdentifier": "t_array$_t_uint256_$dyn_storage", "typeString": "uint256[] storage ref" } }, "nodeType": "VariableDeclarationStatement", "src": "2161:50:0" }, { "expression": { "argumentTypes": null, "id": 266, "name": "ownedAuctions", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 261, "src": "2222:13:0", "typeDescriptions": { "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr", "typeString": "uint256[] memory" } }, "functionReturnParameters": 257, "id": 267, "nodeType": "Return", "src": "2215:20:0" } ] }, "documentation": null, "id": 269, "implemented": true, "isConstructor": false, "isDeclaredConst": true, "modifiers": [], "name": "getAuctionsOf", "nodeType": "FunctionDefinition", "parameters": { "id": 253, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 252, "name": "_owner", "nodeType": "VariableDeclaration", "scope": 269, "src": "2109:14:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 251, "name": "address", "nodeType": "ElementaryTypeName", "src": "2109:7:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "value": null, "visibility": "internal" } ], "src": "2108:16:0" }, "payable": false, "returnParameters": { "id": 257, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 256, "name": "", "nodeType": "VariableDeclaration", "scope": 269, "src": "2149:6:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr", "typeString": "uint256[]" }, "typeName": { "baseType": { "id": 254, "name": "uint", "nodeType": "ElementaryTypeName", "src": "2149:4:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "id": 255, "length": null, "nodeType": "ArrayTypeName", "src": "2149:6:0", "typeDescriptions": { "typeIdentifier": "t_array$_t_uint256_$dyn_storage_ptr", "typeString": "uint256[]" } }, "value": null, "visibility": "internal" } ], "src": "2148:8:0" }, "scope": 341, "src": "2086:153:0", "stateMutability": "view", "superFunction": null, "visibility": "public" }, { "body": { "id": 281, "nodeType": "Block", "src": "2321:42:0", "statements": [ { "expression": { "argumentTypes": null, "expression": { "argumentTypes": null, "baseExpression": { "argumentTypes": null, "id": 276, "name": "auctionOwner", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 10, "src": "2332:12:0", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_array$_t_uint256_$dyn_storage_$", "typeString": "mapping(address => uint256[] storage ref)" } }, "id": 278, "indexExpression": { "argumentTypes": null, "id": 277, "name": "_owner", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 271, "src": "2345:6:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", "src": "2332:20:0", "typeDescriptions": { "typeIdentifier": "t_array$_t_uint256_$dyn_storage", "typeString": "uint256[] storage ref" } }, "id": 279, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "memberName": "length", "nodeType": "MemberAccess", "referencedDeclaration": null, "src": "2332:27:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "functionReturnParameters": 275, "id": 280, "nodeType": "Return", "src": "2325:34:0" } ] }, "documentation": null, "id": 282, "implemented": true, "isConstructor": false, "isDeclaredConst": true, "modifiers": [], "name": "getAuctionsCountOfOwner", "nodeType": "FunctionDefinition", "parameters": { "id": 272, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 271, "name": "_owner", "nodeType": "VariableDeclaration", "scope": 282, "src": "2275:14:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 270, "name": "address", "nodeType": "ElementaryTypeName", "src": "2275:7:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "value": null, "visibility": "internal" } ], "src": "2274:16:0" }, "payable": false, "returnParameters": { "id": 275, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 274, "name": "", "nodeType": "VariableDeclaration", "scope": 282, "src": "2315:4:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 273, "name": "uint", "nodeType": "ElementaryTypeName", "src": "2315:4:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "value": null, "visibility": "internal" } ], "src": "2314:6:0" }, "scope": 341, "src": "2242:121:0", "stateMutability": "view", "superFunction": null, "visibility": "public" }, { "body": { "id": 327, "nodeType": "Block", "src": "2575:188:0", "statements": [ { "assignments": [ 304 ], "declarations": [ { "constant": false, "id": 304, "name": "auc", "nodeType": "VariableDeclaration", "scope": 328, "src": "2579:18:0", "stateVariable": false, "storageLocation": "memory", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction" }, "typeName": { "contractScope": null, "id": 303, "name": "Auction", "nodeType": "UserDefinedTypeName", "referencedDeclaration": 27, "src": "2579:7:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_storage_ptr", "typeString": "struct Auctions.Auction" } }, "value": null, "visibility": "internal" } ], "id": 308, "initialValue": { "argumentTypes": null, "baseExpression": { "argumentTypes": null, "id": 305, "name": "auctions", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 5, "src": "2600:8:0", "typeDescriptions": { "typeIdentifier": "t_array$_t_struct$_Auction_$27_storage_$dyn_storage", "typeString": "struct Auctions.Auction storage ref[] storage ref" } }, "id": 307, "indexExpression": { "argumentTypes": null, "id": 306, "name": "_auctionId", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 284, "src": "2609:10:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", "src": "2600:20:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_storage", "typeString": "struct Auctions.Auction storage ref" } }, "nodeType": "VariableDeclarationStatement", "src": "2579:41:0" }, { "expression": { "argumentTypes": null, "components": [ { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 309, "name": "auc", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 304, "src": "2636:3:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction memory" } }, "id": 310, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "memberName": "name", "nodeType": "MemberAccess", "referencedDeclaration": 12, "src": "2636:8:0", "typeDescriptions": { "typeIdentifier": "t_string_memory", "typeString": "string memory" } }, { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 311, "name": "auc", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 304, "src": "2649:3:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction memory" } }, "id": 312, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "memberName": "price", "nodeType": "MemberAccess", "referencedDeclaration": 14, "src": "2649:9:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 313, "name": "auc", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 304, "src": "2663:3:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction memory" } }, "id": 314, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "memberName": "metadata", "nodeType": "MemberAccess", "referencedDeclaration": 16, "src": "2663:12:0", "typeDescriptions": { "typeIdentifier": "t_string_memory", "typeString": "string memory" } }, { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 315, "name": "auc", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 304, "src": "2680:3:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction memory" } }, "id": 316, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "memberName": "tokenId", "nodeType": "MemberAccess", "referencedDeclaration": 18, "src": "2680:11:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 317, "name": "auc", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 304, "src": "2696:3:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction memory" } }, "id": 318, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "memberName": "repoAddress", "nodeType": "MemberAccess", "referencedDeclaration": 20, "src": "2696:15:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 319, "name": "auc", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 304, "src": "2716:3:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction memory" } }, "id": 320, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "memberName": "owner", "nodeType": "MemberAccess", "referencedDeclaration": 22, "src": "2716:9:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 321, "name": "auc", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 304, "src": "2730:3:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction memory" } }, "id": 322, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "memberName": "active", "nodeType": "MemberAccess", "referencedDeclaration": 24, "src": "2730:10:0", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 323, "name": "auc", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 304, "src": "2745:3:0", "typeDescriptions": { "typeIdentifier": "t_struct$_Auction_$27_memory_ptr", "typeString": "struct Auctions.Auction memory" } }, "id": 324, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "memberName": "finalized", "nodeType": "MemberAccess", "referencedDeclaration": 26, "src": "2745:13:0", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } } ], "id": 325, "isConstant": false, "isInlineArray": false, "isLValue": false, "isPure": false, "lValueRequested": false, "nodeType": "TupleExpression", "src": "2631:128:0", "typeDescriptions": { "typeIdentifier": "t_tuple$_t_string_memory_$_t_uint256_$_t_string_memory_$_t_uint256_$_t_address_$_t_address_$_t_bool_$_t_bool_$", "typeString": "tuple(string memory,uint256,string memory,uint256,address,address,bool,bool)" } }, "functionReturnParameters": 302, "id": 326, "nodeType": "Return", "src": "2624:135:0" } ] }, "documentation": null, "id": 328, "implemented": true, "isConstructor": false, "isDeclaredConst": true, "modifiers": [], "name": "getAuctionById", "nodeType": "FunctionDefinition", "parameters": { "id": 285, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 284, "name": "_auctionId", "nodeType": "VariableDeclaration", "scope": 328, "src": "2390:15:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 283, "name": "uint", "nodeType": "ElementaryTypeName", "src": "2390:4:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "value": null, "visibility": "internal" } ], "src": "2389:17:0" }, "payable": false, "returnParameters": { "id": 302, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 287, "name": "name", "nodeType": "VariableDeclaration", "scope": 328, "src": "2434:11:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_string_memory_ptr", "typeString": "string" }, "typeName": { "id": 286, "name": "string", "nodeType": "ElementaryTypeName", "src": "2434:6:0", "typeDescriptions": { "typeIdentifier": "t_string_storage_ptr", "typeString": "string" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 289, "name": "price", "nodeType": "VariableDeclaration", "scope": 328, "src": "2449:13:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 288, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "2449:7:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 291, "name": "metadata", "nodeType": "VariableDeclaration", "scope": 328, "src": "2466:15:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_string_memory_ptr", "typeString": "string" }, "typeName": { "id": 290, "name": "string", "nodeType": "ElementaryTypeName", "src": "2466:6:0", "typeDescriptions": { "typeIdentifier": "t_string_storage_ptr", "typeString": "string" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 293, "name": "tokenId", "nodeType": "VariableDeclaration", "scope": 328, "src": "2485:15:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 292, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "2485:7:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 295, "name": "repoAddress", "nodeType": "VariableDeclaration", "scope": 328, "src": "2504:19:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 294, "name": "address", "nodeType": "ElementaryTypeName", "src": "2504:7:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 297, "name": "owner", "nodeType": "VariableDeclaration", "scope": 328, "src": "2527:13:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 296, "name": "address", "nodeType": "ElementaryTypeName", "src": "2527:7:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 299, "name": "active", "nodeType": "VariableDeclaration", "scope": 328, "src": "2544:11:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" }, "typeName": { "id": 298, "name": "bool", "nodeType": "ElementaryTypeName", "src": "2544:4:0", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 301, "name": "finalized", "nodeType": "VariableDeclaration", "scope": 328, "src": "2559:14:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" }, "typeName": { "id": 300, "name": "bool", "nodeType": "ElementaryTypeName", "src": "2559:4:0", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "value": null, "visibility": "internal" } ], "src": "2430:144:0" }, "scope": 341, "src": "2366:397:0", "stateMutability": "view", "superFunction": null, "visibility": "public" }, { "anonymous": false, "documentation": null, "id": 334, "name": "AuctionCreated", "nodeType": "EventDefinition", "parameters": { "id": 333, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 330, "indexed": false, "name": "_owner", "nodeType": "VariableDeclaration", "scope": 334, "src": "2787:14:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 329, "name": "address", "nodeType": "ElementaryTypeName", "src": "2787:7:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 332, "indexed": false, "name": "_auctionId", "nodeType": "VariableDeclaration", "scope": 334, "src": "2803:15:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 331, "name": "uint", "nodeType": "ElementaryTypeName", "src": "2803:4:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "value": null, "visibility": "internal" } ], "src": "2786:33:0" }, "src": "2766:54:0" }, { "anonymous": false, "documentation": null, "id": 340, "name": "AuctionFinalized", "nodeType": "EventDefinition", "parameters": { "id": 339, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 336, "indexed": false, "name": "_owner", "nodeType": "VariableDeclaration", "scope": 340, "src": "2845:14:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 335, "name": "address", "nodeType": "ElementaryTypeName", "src": "2845:7:0", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 338, "indexed": false, "name": "_auctionId", "nodeType": "VariableDeclaration", "scope": 340, "src": "2861:15:0", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 337, "name": "uint", "nodeType": "ElementaryTypeName", "src": "2861:4:0", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "value": null, "visibility": "internal" } ], "src": "2844:33:0" }, "src": "2822:56:0" } ], "scope": 342, "src": "49:2831:0" } ], "src": "0:2881:0" }, "compiler": { "name": "solc", "version": "0.4.25+commit.59dbf8f1.Emscripten.clang" }, "networks": { "1001": { "events": {}, "links": {}, "address": "0x3a235ca1b8d08f2f5d6607f8b9f4fa33f540fed6", "transactionHash": "0x99af8cdea2dd01bc0adb40607b621b3b73e9a7cd7ddcdb21d01c4331e0f8d408" }, "5777": { "events": {}, "links": {}, "address": "0x5ffc6ca35a7ee8ed33228b47b49c21310e67339c", "transactionHash": "0xa56ec1dd278986ddd96cfebd400d3e24a65988c73d62216cc38b28cade37127b" } }, "schemaVersion": "2.0.2", "updatedAt": "2020-03-25T02:14:31.606Z" }