Skip to content

Instantly share code, notes, and snippets.

@tinybike
Last active October 5, 2017 19:25
Show Gist options
  • Save tinybike/53091a5a3d2689b50269304941c348b4 to your computer and use it in GitHub Desktop.
Save tinybike/53091a5a3d2689b50269304941c348b4 to your computer and use it in GitHub Desktop.
pragma solidity ^0.4.13;
// AUDIT/CONSIDER: Is it better that this contract provide generic functions that are limited to whitelisted callers or for it to have many specific functions which have more limited and specific validation?
contract Augur {
enum ReportingPhase {
DesignatedReporter, LimitedReporters, AllReporters
}
// misc events
event TokensTransferred(address indexed token, address indexed from, address indexed to, uint256 value);
// reporting events
event MarketCreated(address indexed market, address indexed marketCreator, uint256 marketCreationFee, string extraInfo);
event ReporterRegistered(address indexed reporter, address indexed reportingWindow);
event DesignatedReportSubmitted(address indexed designatedReporter, address indexed market, uint256[] payoutNumerators);
event ReportSubmitted(address indexed reporter, address indexed market, address reportingToken, uint256 amountStaked, uint256[] payoutNumerators);
event WinningTokensRedeemed(address indexed reporter, address indexed market, address reportingToken, uint256 amountRedeemed, address reportingFeesReceived, uint256[] payoutNumerators);
event ReportsDisputed(address indexed disputer, address indexed market, ReportingPhase reportingPhase, uint256 disputeBondAmount);
event MarketFinalized(address indexed market);
event UniverseForked(address indexed universe);
// trading events
event OrderCanceled(address indexed shareToken, address indexed sender, bytes32 orderId, uint8 orderType, uint256 tokenRefund, uint256 sharesRefund);
event OrderCreated(address indexed shareToken, address indexed creator, bytes32 indexed orderId, int256 price, uint256 amount, uint256 numTokensEscrowed, uint256 numSharesEscrowed, bytes32 tradeGroupId);
event OrderFilled(address indexed shareToken, address indexed creator, address indexed filler, int256 price, uint256 numCreatorShares, uint256 numCreatorTokens, uint256 numFillerShares, uint256 numFillerTokens, uint256 settlementFees, bytes32 tradeGroupId);
event ProceedsClaimed(address indexed sender, address indexed market, uint256 numShares, uint256 numPayoutTokens, uint256 finalTokenBalance);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment