Skip to content

Instantly share code, notes, and snippets.

@nicovalencia
Created June 1, 2018 14:46
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save nicovalencia/039a8ccca9d8a93bb25063ec9513d3e2 to your computer and use it in GitHub Desktop.
Save nicovalencia/039a8ccca9d8a93bb25063ec9513d3e2 to your computer and use it in GitHub Desktop.
mapping (uint256 => Auction) auctionsByTokenId
struct Auction {
address highestBidder
uint256 highestBidAmount
uint256 endsAtBlock
uint256 tokenId
}
uint256 constant INITIAL_BID = 0.01 eth
uint256 constant MIN_BID_INCREMENT = 0.01 eth
uint256 constant EXPIRED_TOKEN_COST = 0.05 eth
uint256 constant AUCTION_BLOCK_LENGTH = 247
uint256 totalUnclaimedBidsAmount = 0
mapping (uint256 => mapping(address => uint256)) unclaimedBidsByTokenByBidder
function createAuction(uint256 tokenId) public onlyOwner {}
function incrementBid(uint256 tokenId) public payable {}
function finalizeAuction(uint256 tokenId) public {}
function buyExpiredToken(uint256 tokenId) public payable {}
function withdraw(address recipient) public onlyOwner {}
function returnBids(uint256 tokenId, address bidder) public {}
function () payable {}
event AuctionCreated(uint256 tokenId)
event BidIncremented(uint256 tokenId)
contract AuctionBroker {}mapping (u
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment