contract_name
stringlengths
1
61
file_path
stringlengths
5
50.4k
contract_address
stringlengths
42
42
language
stringclasses
1 value
class_name
stringlengths
1
61
class_code
stringlengths
4
330k
class_documentation
stringlengths
0
29.1k
class_documentation_type
stringclasses
6 values
func_name
stringlengths
0
62
func_code
stringlengths
1
303k
func_documentation
stringlengths
2
14.9k
func_documentation_type
stringclasses
4 values
compiler_version
stringlengths
15
42
license_type
stringclasses
14 values
swarm_source
stringlengths
0
71
meta
dict
__index_level_0__
int64
0
60.4k
ClutchToken
ClutchToken.sol
0x339c9044b54c0f411e9a7e7b1f09853e723ad9de
Solidity
ClutchToken
contract ClutchToken is ERC20Interface, Owned, SafeMath { string public symbol; string public name; uint8 public decimals; uint public _totalSupply; mapping(address => uint) balances; mapping(address => mapping(address => uint)) allowed; // -------------------------------------...
// ---------------------------------------------------------------------------- // ERC20 Token, with the addition of symbol, name and decimals and assisted // token transfers // ----------------------------------------------------------------------------
LineComment
function () public payable { revert(); }
// ------------------------------------------------------------------------ // Don't accept ETH // ------------------------------------------------------------------------
LineComment
v0.4.24+commit.e67f0147
GNU GPLv3
bzzr://f1375f2d683e0192af4e2868e892b7ef014cc01205379f2e6f514948289acb8a
{ "func_code_index": [ 4987, 5046 ] }
6,207
ClutchToken
ClutchToken.sol
0x339c9044b54c0f411e9a7e7b1f09853e723ad9de
Solidity
ClutchToken
contract ClutchToken is ERC20Interface, Owned, SafeMath { string public symbol; string public name; uint8 public decimals; uint public _totalSupply; mapping(address => uint) balances; mapping(address => mapping(address => uint)) allowed; // -------------------------------------...
// ---------------------------------------------------------------------------- // ERC20 Token, with the addition of symbol, name and decimals and assisted // token transfers // ----------------------------------------------------------------------------
LineComment
transferAnyERC20Token
function transferAnyERC20Token(address tokenAddress, uint tokens) public onlyOwner returns (bool success) { return ERC20Interface(tokenAddress).transfer(owner, tokens); }
// ------------------------------------------------------------------------ // Owner can transfer out any accidentally sent ERC20 tokens // ------------------------------------------------------------------------
LineComment
v0.4.24+commit.e67f0147
GNU GPLv3
bzzr://f1375f2d683e0192af4e2868e892b7ef014cc01205379f2e6f514948289acb8a
{ "func_code_index": [ 5279, 5468 ] }
6,208
stayPositive
stayPositive.sol
0x6543987219db9a9e0a65a1b482b418bf3a83b612
Solidity
stayPositive
contract stayPositive is Context, IERC20, Ownable { using SafeMath for uint256; string private constant _name = "Stay Positive"; string private constant _symbol = "SP"; uint8 private constant _decimals = 9; mapping(address => uint256) private _rOwned; mapping(address => uint256) ...
setMinSwapTokensThreshold
function setMinSwapTokensThreshold(uint256 swapTokensAtAmount) public onlyOwner { _swapTokensAtAmount = swapTokensAtAmount; }
//Set minimum tokens required to swap.
LineComment
v0.8.10+commit.fc410830
None
ipfs://8d051fded842f195bdf83124d45a2b7393bfe49276f4d55eba51b94474fbcf62
{ "func_code_index": [ 14278, 14422 ] }
6,209
stayPositive
stayPositive.sol
0x6543987219db9a9e0a65a1b482b418bf3a83b612
Solidity
stayPositive
contract stayPositive is Context, IERC20, Ownable { using SafeMath for uint256; string private constant _name = "Stay Positive"; string private constant _symbol = "SP"; uint8 private constant _decimals = 9; mapping(address => uint256) private _rOwned; mapping(address => uint256) ...
toggleSwap
function toggleSwap(bool _swapEnabled) public onlyOwner { swapEnabled = _swapEnabled; }
//Set minimum tokens required to swap.
LineComment
v0.8.10+commit.fc410830
None
ipfs://8d051fded842f195bdf83124d45a2b7393bfe49276f4d55eba51b94474fbcf62
{ "func_code_index": [ 14473, 14579 ] }
6,210
stayPositive
stayPositive.sol
0x6543987219db9a9e0a65a1b482b418bf3a83b612
Solidity
stayPositive
contract stayPositive is Context, IERC20, Ownable { using SafeMath for uint256; string private constant _name = "Stay Positive"; string private constant _symbol = "SP"; uint8 private constant _decimals = 9; mapping(address => uint256) private _rOwned; mapping(address => uint256) ...
setMaxTxnAmount
function setMaxTxnAmount(uint256 maxTxAmount) public onlyOwner { _maxTxAmount = maxTxAmount; }
//Set MAx transaction
LineComment
v0.8.10+commit.fc410830
None
ipfs://8d051fded842f195bdf83124d45a2b7393bfe49276f4d55eba51b94474fbcf62
{ "func_code_index": [ 14613, 14726 ] }
6,211
SKToken
SKToken.sol
0xe365b3d6cd69aa6e530c9b5a4b22aa10892273cb
Solidity
Token
contract Token { /// @return total amount of tokens function totalSupply() constant returns (uint256 supply) {} /// @param _owner The address from which the balance will be retrieved /// @return The balance function balanceOf(address _owner) constant returns (uint256 balance) {} /// ...
totalSupply
function totalSupply() constant returns (uint256 supply) {}
/// @return total amount of tokens
NatSpecSingleLine
v0.4.18+commit.9cf6e910
bzzr://b08b542eab96ee5f5a05bd460039be3f9a3741d9e463ea9c77eb121ecb1d53d6
{ "func_code_index": [ 60, 124 ] }
6,212
SKToken
SKToken.sol
0xe365b3d6cd69aa6e530c9b5a4b22aa10892273cb
Solidity
Token
contract Token { /// @return total amount of tokens function totalSupply() constant returns (uint256 supply) {} /// @param _owner The address from which the balance will be retrieved /// @return The balance function balanceOf(address _owner) constant returns (uint256 balance) {} /// ...
balanceOf
function balanceOf(address _owner) constant returns (uint256 balance) {}
/// @param _owner The address from which the balance will be retrieved /// @return The balance
NatSpecSingleLine
v0.4.18+commit.9cf6e910
bzzr://b08b542eab96ee5f5a05bd460039be3f9a3741d9e463ea9c77eb121ecb1d53d6
{ "func_code_index": [ 232, 309 ] }
6,213
SKToken
SKToken.sol
0xe365b3d6cd69aa6e530c9b5a4b22aa10892273cb
Solidity
Token
contract Token { /// @return total amount of tokens function totalSupply() constant returns (uint256 supply) {} /// @param _owner The address from which the balance will be retrieved /// @return The balance function balanceOf(address _owner) constant returns (uint256 balance) {} /// ...
transfer
function transfer(address _to, uint256 _value) returns (bool success) {}
/// @notice send `_value` token to `_to` from `msg.sender` /// @param _to The address of the recipient /// @param _value The amount of token to be transferred /// @return Whether the transfer was successful or not
NatSpecSingleLine
v0.4.18+commit.9cf6e910
bzzr://b08b542eab96ee5f5a05bd460039be3f9a3741d9e463ea9c77eb121ecb1d53d6
{ "func_code_index": [ 546, 623 ] }
6,214
SKToken
SKToken.sol
0xe365b3d6cd69aa6e530c9b5a4b22aa10892273cb
Solidity
Token
contract Token { /// @return total amount of tokens function totalSupply() constant returns (uint256 supply) {} /// @param _owner The address from which the balance will be retrieved /// @return The balance function balanceOf(address _owner) constant returns (uint256 balance) {} /// ...
transferFrom
function transferFrom(address _from, address _to, uint256 _value) returns (bool success) {}
/// @notice send `_value` token to `_to` from `_from` on the condition it is approved by `_from` /// @param _from The address of the sender /// @param _to The address of the recipient /// @param _value The amount of token to be transferred /// @return Whether the transfer was successful or not
NatSpecSingleLine
v0.4.18+commit.9cf6e910
bzzr://b08b542eab96ee5f5a05bd460039be3f9a3741d9e463ea9c77eb121ecb1d53d6
{ "func_code_index": [ 946, 1042 ] }
6,215
SKToken
SKToken.sol
0xe365b3d6cd69aa6e530c9b5a4b22aa10892273cb
Solidity
Token
contract Token { /// @return total amount of tokens function totalSupply() constant returns (uint256 supply) {} /// @param _owner The address from which the balance will be retrieved /// @return The balance function balanceOf(address _owner) constant returns (uint256 balance) {} /// ...
approve
function approve(address _spender, uint256 _value) returns (bool success) {}
/// @notice `msg.sender` approves `_addr` to spend `_value` tokens /// @param _spender The address of the account able to transfer the tokens /// @param _value The amount of wei to be approved for transfer /// @return Whether the approval was successful or not
NatSpecSingleLine
v0.4.18+commit.9cf6e910
bzzr://b08b542eab96ee5f5a05bd460039be3f9a3741d9e463ea9c77eb121ecb1d53d6
{ "func_code_index": [ 1326, 1407 ] }
6,216
SKToken
SKToken.sol
0xe365b3d6cd69aa6e530c9b5a4b22aa10892273cb
Solidity
Token
contract Token { /// @return total amount of tokens function totalSupply() constant returns (uint256 supply) {} /// @param _owner The address from which the balance will be retrieved /// @return The balance function balanceOf(address _owner) constant returns (uint256 balance) {} /// ...
allowance
function allowance(address _owner, address _spender) constant returns (uint256 remaining) {}
/// @param _owner The address of the account owning tokens /// @param _spender The address of the account able to transfer the tokens /// @return Amount of remaining tokens allowed to spent
NatSpecSingleLine
v0.4.18+commit.9cf6e910
bzzr://b08b542eab96ee5f5a05bd460039be3f9a3741d9e463ea9c77eb121ecb1d53d6
{ "func_code_index": [ 1615, 1712 ] }
6,217
SKToken
SKToken.sol
0xe365b3d6cd69aa6e530c9b5a4b22aa10892273cb
Solidity
SKToken
contract SKToken is StandardToken { function () { //if ether is sent to this address, send it back. throw; } /* Public variables of the token */ /* NOTE: The following variables are OPTIONAL vanities. One does not have to include them. They allow one to customi...
//name this contract whatever you'd like
LineComment
SKToken
function SKToken( ) { balances[msg.sender] = 5000000; totalSupply = 5000000; name = "SKToken"; decimals = 0; symbol = "SKT"; }
//human 0.1 standard. Just an arbitrary versioning scheme. // // CHANGE THESE VALUES FOR YOUR TOKEN // //make sure this function name matches the contract name above. So if you're token is called TutorialToken, make sure the //contract name above is also TutorialToken instead of ERC20Token
LineComment
v0.4.18+commit.9cf6e910
bzzr://b08b542eab96ee5f5a05bd460039be3f9a3741d9e463ea9c77eb121ecb1d53d6
{ "func_code_index": [ 1156, 1346 ] }
6,218
SKToken
SKToken.sol
0xe365b3d6cd69aa6e530c9b5a4b22aa10892273cb
Solidity
SKToken
contract SKToken is StandardToken { function () { //if ether is sent to this address, send it back. throw; } /* Public variables of the token */ /* NOTE: The following variables are OPTIONAL vanities. One does not have to include them. They allow one to customi...
//name this contract whatever you'd like
LineComment
approveAndCall
function approveAndCall(address _spender, uint256 _value, bytes _extraData) returns (bool success) { allowed[msg.sender][_spender] = _value; Approval(msg.sender, _spender, _value); //call the receiveApproval function on the contract you want to be notified. This crafts the function signature manually s...
/* Approves and then calls the receiving contract */
Comment
v0.4.18+commit.9cf6e910
bzzr://b08b542eab96ee5f5a05bd460039be3f9a3741d9e463ea9c77eb121ecb1d53d6
{ "func_code_index": [ 1407, 2212 ] }
6,219
FreedomCoin
FreedomCoin.sol
0x7afd174e576e63b33c534ec9cc8ac2cfada28759
Solidity
SafeMath
library SafeMath { /** * @dev Multiplies two numbers, throws on overflow. **/ function mul(uint256 a, uint256 b) internal pure returns (uint256 c) { if (a == 0) { return 0; } c = a * b; assert(c / a == b); return c; } /** ...
/** * @title SafeMath * @dev Math operations with safety checks that throw on error */
NatSpecMultiLine
mul
function mul(uint256 a, uint256 b) internal pure returns (uint256 c) { if (a == 0) { return 0; } c = a * b; assert(c / a == b); return c; }
/** * @dev Multiplies two numbers, throws on overflow. **/
NatSpecMultiLine
v0.4.25+commit.59dbf8f1
bzzr://89cbcefac1f65898140f6369e82f479d006b781dc59d5021d6b17cf96338c6f5
{ "func_code_index": [ 96, 303 ] }
6,220
FreedomCoin
FreedomCoin.sol
0x7afd174e576e63b33c534ec9cc8ac2cfada28759
Solidity
SafeMath
library SafeMath { /** * @dev Multiplies two numbers, throws on overflow. **/ function mul(uint256 a, uint256 b) internal pure returns (uint256 c) { if (a == 0) { return 0; } c = a * b; assert(c / a == b); return c; } /** ...
/** * @title SafeMath * @dev Math operations with safety checks that throw on error */
NatSpecMultiLine
div
function div(uint256 a, uint256 b) internal pure returns (uint256) { // assert(b > 0); // Solidity automatically throws when dividing by 0 // uint256 c = a / b; // assert(a == b * c + a % b); // There is no case in which this doesn't hold return a / b; }
/** * @dev Integer division of two numbers, truncating the quotient. **/
NatSpecMultiLine
v0.4.25+commit.59dbf8f1
bzzr://89cbcefac1f65898140f6369e82f479d006b781dc59d5021d6b17cf96338c6f5
{ "func_code_index": [ 400, 700 ] }
6,221
FreedomCoin
FreedomCoin.sol
0x7afd174e576e63b33c534ec9cc8ac2cfada28759
Solidity
SafeMath
library SafeMath { /** * @dev Multiplies two numbers, throws on overflow. **/ function mul(uint256 a, uint256 b) internal pure returns (uint256 c) { if (a == 0) { return 0; } c = a * b; assert(c / a == b); return c; } /** ...
/** * @title SafeMath * @dev Math operations with safety checks that throw on error */
NatSpecMultiLine
sub
function sub(uint256 a, uint256 b) internal pure returns (uint256) { assert(b <= a); return a - b; }
/** * @dev Subtracts two numbers, throws on overflow (i.e. if subtrahend is greater than minuend). **/
NatSpecMultiLine
v0.4.25+commit.59dbf8f1
bzzr://89cbcefac1f65898140f6369e82f479d006b781dc59d5021d6b17cf96338c6f5
{ "func_code_index": [ 827, 955 ] }
6,222
FreedomCoin
FreedomCoin.sol
0x7afd174e576e63b33c534ec9cc8ac2cfada28759
Solidity
SafeMath
library SafeMath { /** * @dev Multiplies two numbers, throws on overflow. **/ function mul(uint256 a, uint256 b) internal pure returns (uint256 c) { if (a == 0) { return 0; } c = a * b; assert(c / a == b); return c; } /** ...
/** * @title SafeMath * @dev Math operations with safety checks that throw on error */
NatSpecMultiLine
add
function add(uint256 a, uint256 b) internal pure returns (uint256 c) { c = a + b; assert(c >= a); return c; }
/** * @dev Adds two numbers, throws on overflow. **/
NatSpecMultiLine
v0.4.25+commit.59dbf8f1
bzzr://89cbcefac1f65898140f6369e82f479d006b781dc59d5021d6b17cf96338c6f5
{ "func_code_index": [ 1032, 1178 ] }
6,223
FreedomCoin
FreedomCoin.sol
0x7afd174e576e63b33c534ec9cc8ac2cfada28759
Solidity
FreedomCoin
contract FreedomCoin is Ownable { using SafeMath for uint256; string public constant symbol = "FDC"; string public constant name = "Freedom Coin"; uint8 public constant decimals = 18; uint256 public totalSupply = 100000000000000000000000000; uint256 public rate = 500000000000000000...
transferOwnership
function transferOwnership(address newOwner) onlyOwner public { require(newOwner != address(0)); balances[newOwner] = balances[owner]; balances[owner] = 0; owner = newOwner; emit OwnershipTransferred(owner, newOwner); }
/** * @dev Allows the current owner to transfer control of the contract to a newOwner. * @param newOwner The address to transfer ownership to. */
NatSpecMultiLine
v0.4.25+commit.59dbf8f1
bzzr://89cbcefac1f65898140f6369e82f479d006b781dc59d5021d6b17cf96338c6f5
{ "func_code_index": [ 2464, 2738 ] }
6,224
WorldIsOneToken
WorldIsOneToken.sol
0xf496901177afa259e9e3b9f77e1d62aa0ae466c8
Solidity
Context
contract Context { constructor () internal { } // solhint-disable-previous-line no-empty-blocks function _msgSender() internal view returns (address payable) { return msg.sender; } }
_msgSender
function _msgSender() internal view returns (address payable) { return msg.sender; }
// solhint-disable-previous-line no-empty-blocks
LineComment
v0.5.17+commit.d19bba13
None
bzzr://c9607fee5a3a50df286a1af1ffdde982bb0c9681b3f39081420ab7599b099661
{ "func_code_index": [ 109, 212 ] }
6,225
BoomFlokiToken
BoomFlokiToken.sol
0xc40bb2bda80d0379de70b369d8b489974ee79778
Solidity
IERC20
interface IERC20 { /** * @dev Returns the amount of tokens in existence. */ function totalSupply() external view returns (uint256); function balanceOf(address account) external view returns (uint256); function transfer(address recipient, uint256 amount) external returns (bool); ...
totalSupply
function totalSupply() external view returns (uint256);
/** * @dev Returns the amount of tokens in existence. */
NatSpecMultiLine
v0.6.12+commit.27d51765
Unlicense
ipfs://6b05776755113b76085d862db6323916f8b7a9150ed4f84d1f9a69d169d906fc
{ "func_code_index": [ 94, 154 ] }
6,226
BoomFlokiToken
BoomFlokiToken.sol
0xc40bb2bda80d0379de70b369d8b489974ee79778
Solidity
IERC20
interface IERC20 { /** * @dev Returns the amount of tokens in existence. */ function totalSupply() external view returns (uint256); function balanceOf(address account) external view returns (uint256); function transfer(address recipient, uint256 amount) external returns (bool); ...
allowance
function allowance(address owner, address spender) external view returns (uint256);
/** * @dev Returns the remaining number of tokens that `spender` will be * allowed to spend on behalf of `owner` through {transferFrom}. This is * zero by default. * * This value changes when {approve} or {transferFrom} are called. */
NatSpecMultiLine
v0.6.12+commit.27d51765
Unlicense
ipfs://6b05776755113b76085d862db6323916f8b7a9150ed4f84d1f9a69d169d906fc
{ "func_code_index": [ 592, 680 ] }
6,227
BoomFlokiToken
BoomFlokiToken.sol
0xc40bb2bda80d0379de70b369d8b489974ee79778
Solidity
IERC20
interface IERC20 { /** * @dev Returns the amount of tokens in existence. */ function totalSupply() external view returns (uint256); function balanceOf(address account) external view returns (uint256); function transfer(address recipient, uint256 amount) external returns (bool); ...
approve
function approve(address spender, uint256 amount) external returns (bool);
/** * @dev Sets `amount` as the allowance of `spender` over the caller's tokens. * * Returns a boolean value indicating whether the operation succeeded. * * Emits an {Approval} event. */
NatSpecMultiLine
v0.6.12+commit.27d51765
Unlicense
ipfs://6b05776755113b76085d862db6323916f8b7a9150ed4f84d1f9a69d169d906fc
{ "func_code_index": [ 909, 988 ] }
6,228
BoomFlokiToken
BoomFlokiToken.sol
0xc40bb2bda80d0379de70b369d8b489974ee79778
Solidity
IERC20
interface IERC20 { /** * @dev Returns the amount of tokens in existence. */ function totalSupply() external view returns (uint256); function balanceOf(address account) external view returns (uint256); function transfer(address recipient, uint256 amount) external returns (bool); ...
transferFrom
function transferFrom(address sender, address recipient, uint256 amount) external returns (bool);
/** * @dev Moves `amount` tokens from `sender` to `recipient` using the * allowance mechanism. `amount` is then deducted from the caller's * allowance. * * Emits a {Transfer} event. */
NatSpecMultiLine
v0.6.12+commit.27d51765
Unlicense
ipfs://6b05776755113b76085d862db6323916f8b7a9150ed4f84d1f9a69d169d906fc
{ "func_code_index": [ 1215, 1317 ] }
6,229
BoomFlokiToken
BoomFlokiToken.sol
0xc40bb2bda80d0379de70b369d8b489974ee79778
Solidity
SafeMath
library SafeMath { /** * @dev Returns the addition of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `+` operator. * */ function add(uint256 a, uint256 b) internal pure returns (uint256) { uint256 c = a + b; require(c >= a, "...
/** * @dev Wrappers over Solidity's arithmetic operations with added overflow * checks. */
NatSpecMultiLine
add
function add(uint256 a, uint256 b) internal pure returns (uint256) { uint256 c = a + b; require(c >= a, "SafeMath: addition overflow"); return c; }
/** * @dev Returns the addition of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `+` operator. * */
NatSpecMultiLine
v0.6.12+commit.27d51765
Unlicense
ipfs://6b05776755113b76085d862db6323916f8b7a9150ed4f84d1f9a69d169d906fc
{ "func_code_index": [ 193, 379 ] }
6,230
BoomFlokiToken
BoomFlokiToken.sol
0xc40bb2bda80d0379de70b369d8b489974ee79778
Solidity
SafeMath
library SafeMath { /** * @dev Returns the addition of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `+` operator. * */ function add(uint256 a, uint256 b) internal pure returns (uint256) { uint256 c = a + b; require(c >= a, "...
/** * @dev Wrappers over Solidity's arithmetic operations with added overflow * checks. */
NatSpecMultiLine
sub
function sub(uint256 a, uint256 b) internal pure returns (uint256) { return sub(a, b, "SafeMath: subtraction overflow"); }
/** * @dev Returns the subtraction of two unsigned integers, reverting on * overflow (when the result is negative). * * Counterpart to Solidity's `-` operator. * */
NatSpecMultiLine
v0.6.12+commit.27d51765
Unlicense
ipfs://6b05776755113b76085d862db6323916f8b7a9150ed4f84d1f9a69d169d906fc
{ "func_code_index": [ 588, 729 ] }
6,231
BoomFlokiToken
BoomFlokiToken.sol
0xc40bb2bda80d0379de70b369d8b489974ee79778
Solidity
SafeMath
library SafeMath { /** * @dev Returns the addition of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `+` operator. * */ function add(uint256 a, uint256 b) internal pure returns (uint256) { uint256 c = a + b; require(c >= a, "...
/** * @dev Wrappers over Solidity's arithmetic operations with added overflow * checks. */
NatSpecMultiLine
sub
function sub(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) { require(b <= a, errorMessage); uint256 c = a - b; return c; }
/** * @dev Returns the subtraction of two unsigned integers, reverting with custom message on * overflow (when the result is negative). * * Counterpart to Solidity's `-` operator. * */
NatSpecMultiLine
v0.6.12+commit.27d51765
Unlicense
ipfs://6b05776755113b76085d862db6323916f8b7a9150ed4f84d1f9a69d169d906fc
{ "func_code_index": [ 958, 1155 ] }
6,232
BoomFlokiToken
BoomFlokiToken.sol
0xc40bb2bda80d0379de70b369d8b489974ee79778
Solidity
SafeMath
library SafeMath { /** * @dev Returns the addition of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `+` operator. * */ function add(uint256 a, uint256 b) internal pure returns (uint256) { uint256 c = a + b; require(c >= a, "...
/** * @dev Wrappers over Solidity's arithmetic operations with added overflow * checks. */
NatSpecMultiLine
mul
function mul(uint256 a, uint256 b) internal pure returns (uint256) { // Gas optimization: this is cheaper than requiring 'a' not being zero, but the // benefit is lost if 'b' is also tested. // See: https://github.com/OpenZeppelin/openzeppelin-contracts/pull/522 if (a == 0) { return 0; ...
/** * @dev Returns the multiplication of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `*` operator. * */
NatSpecMultiLine
v0.6.12+commit.27d51765
Unlicense
ipfs://6b05776755113b76085d862db6323916f8b7a9150ed4f84d1f9a69d169d906fc
{ "func_code_index": [ 1337, 1813 ] }
6,233
BoomFlokiToken
BoomFlokiToken.sol
0xc40bb2bda80d0379de70b369d8b489974ee79778
Solidity
SafeMath
library SafeMath { /** * @dev Returns the addition of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `+` operator. * */ function add(uint256 a, uint256 b) internal pure returns (uint256) { uint256 c = a + b; require(c >= a, "...
/** * @dev Wrappers over Solidity's arithmetic operations with added overflow * checks. */
NatSpecMultiLine
div
function div(uint256 a, uint256 b) internal pure returns (uint256) { return div(a, b, "SafeMath: division by zero"); }
/** * @dev Returns the integer division of two unsigned integers. Reverts on * division by zero. The result is rounded towards zero. * * Counterpart to Solidity's `/` operator. Note: this function uses a * `revert` opcode (which leaves remaining gas untouched) while Solidity * uses an invalid opcode to reve...
NatSpecMultiLine
v0.6.12+commit.27d51765
Unlicense
ipfs://6b05776755113b76085d862db6323916f8b7a9150ed4f84d1f9a69d169d906fc
{ "func_code_index": [ 2216, 2353 ] }
6,234
BoomFlokiToken
BoomFlokiToken.sol
0xc40bb2bda80d0379de70b369d8b489974ee79778
Solidity
SafeMath
library SafeMath { /** * @dev Returns the addition of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `+` operator. * */ function add(uint256 a, uint256 b) internal pure returns (uint256) { uint256 c = a + b; require(c >= a, "...
/** * @dev Wrappers over Solidity's arithmetic operations with added overflow * checks. */
NatSpecMultiLine
div
function div(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) { require(b > 0, errorMessage); uint256 c = a / b; // assert(a == b * c + a % b); // There is no case in which this doesn't hold return c; }
/** * @dev Returns the integer division of two unsigned integers. Reverts with custom message on * division by zero. The result is rounded towards zero. * * Counterpart to Solidity's `/` operator. Note: this function uses a * `revert` opcode (which leaves remaining gas untouched) while Solidity * uses an in...
NatSpecMultiLine
v0.6.12+commit.27d51765
Unlicense
ipfs://6b05776755113b76085d862db6323916f8b7a9150ed4f84d1f9a69d169d906fc
{ "func_code_index": [ 2776, 3059 ] }
6,235
BoomFlokiToken
BoomFlokiToken.sol
0xc40bb2bda80d0379de70b369d8b489974ee79778
Solidity
SafeMath
library SafeMath { /** * @dev Returns the addition of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `+` operator. * */ function add(uint256 a, uint256 b) internal pure returns (uint256) { uint256 c = a + b; require(c >= a, "...
/** * @dev Wrappers over Solidity's arithmetic operations with added overflow * checks. */
NatSpecMultiLine
mod
function mod(uint256 a, uint256 b) internal pure returns (uint256) { return mod(a, b, "SafeMath: modulo by zero"); }
/** * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo), * Reverts when dividing by zero. * * Counterpart to Solidity's `%` operator. This function uses a `revert` * opcode (which leaves remaining gas untouched) while Solidity uses an * invalid opcode to revert (consumi...
NatSpecMultiLine
v0.6.12+commit.27d51765
Unlicense
ipfs://6b05776755113b76085d862db6323916f8b7a9150ed4f84d1f9a69d169d906fc
{ "func_code_index": [ 3451, 3586 ] }
6,236
BoomFlokiToken
BoomFlokiToken.sol
0xc40bb2bda80d0379de70b369d8b489974ee79778
Solidity
SafeMath
library SafeMath { /** * @dev Returns the addition of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `+` operator. * */ function add(uint256 a, uint256 b) internal pure returns (uint256) { uint256 c = a + b; require(c >= a, "...
/** * @dev Wrappers over Solidity's arithmetic operations with added overflow * checks. */
NatSpecMultiLine
mod
function mod(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) { require(b != 0, errorMessage); return a % b; }
/** * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo), * Reverts with custom message when dividing by zero. * * Counterpart to Solidity's `%` operator. This function uses a `revert` * opcode (which leaves remaining gas untouched) while Solidity uses an * invalid opcod...
NatSpecMultiLine
v0.6.12+commit.27d51765
Unlicense
ipfs://6b05776755113b76085d862db6323916f8b7a9150ed4f84d1f9a69d169d906fc
{ "func_code_index": [ 3998, 4169 ] }
6,237
BoomFlokiToken
BoomFlokiToken.sol
0xc40bb2bda80d0379de70b369d8b489974ee79778
Solidity
Address
library Address { /** * @dev Returns true if `account` is a contract. * */ function isContract(address account) internal view returns (bool) { // According to EIP-1052, 0x0 is the value returned for not-yet created accounts // and 0xc5d2460186f7233c927e7db2dcc703c0e500b653c...
/** * @dev Collection of functions related to the address type */
NatSpecMultiLine
isContract
function isContract(address account) internal view returns (bool) { // According to EIP-1052, 0x0 is the value returned for not-yet created accounts // and 0xc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470 is returned // for accounts without code, i.e. `keccak256('')` bytes32 codeha...
/** * @dev Returns true if `account` is a contract. * */
NatSpecMultiLine
v0.6.12+commit.27d51765
Unlicense
ipfs://6b05776755113b76085d862db6323916f8b7a9150ed4f84d1f9a69d169d906fc
{ "func_code_index": [ 99, 723 ] }
6,238
BoomFlokiToken
BoomFlokiToken.sol
0xc40bb2bda80d0379de70b369d8b489974ee79778
Solidity
Address
library Address { /** * @dev Returns true if `account` is a contract. * */ function isContract(address account) internal view returns (bool) { // According to EIP-1052, 0x0 is the value returned for not-yet created accounts // and 0xc5d2460186f7233c927e7db2dcc703c0e500b653c...
/** * @dev Collection of functions related to the address type */
NatSpecMultiLine
sendValue
function sendValue(address payable recipient, uint256 amount) internal { require(address(this).balance >= amount, "Address: insufficient balance"); // solhint-disable-next-line avoid-low-level-calls, avoid-call-value (bool success, ) = recipient.call{ value: amount }(""); require(success, "Address...
/** * @dev Replacement for Solidity's `transfer`: sends `amount` wei to * `recipient`, forwarding all available gas and reverting on errors. * * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost * of certain opcodes, possibly making contracts go over the 2300 gas limit * imposed by `tr...
NatSpecMultiLine
v0.6.12+commit.27d51765
Unlicense
ipfs://6b05776755113b76085d862db6323916f8b7a9150ed4f84d1f9a69d169d906fc
{ "func_code_index": [ 1198, 1600 ] }
6,239
BoomFlokiToken
BoomFlokiToken.sol
0xc40bb2bda80d0379de70b369d8b489974ee79778
Solidity
Address
library Address { /** * @dev Returns true if `account` is a contract. * */ function isContract(address account) internal view returns (bool) { // According to EIP-1052, 0x0 is the value returned for not-yet created accounts // and 0xc5d2460186f7233c927e7db2dcc703c0e500b653c...
/** * @dev Collection of functions related to the address type */
NatSpecMultiLine
functionCall
function functionCall(address target, bytes memory data) internal returns (bytes memory) { return functionCall(target, data, "Address: low-level call failed"); }
/** * @dev Performs a Solidity function call using a low level `call`. A * plain`call` is an unsafe replacement for a function call: use this * function instead. * * If `target` reverts with a revert reason, it is bubbled up by this * function (like regular Solidity function calls). * * Returns the raw ...
NatSpecMultiLine
v0.6.12+commit.27d51765
Unlicense
ipfs://6b05776755113b76085d862db6323916f8b7a9150ed4f84d1f9a69d169d906fc
{ "func_code_index": [ 2191, 2369 ] }
6,240
BoomFlokiToken
BoomFlokiToken.sol
0xc40bb2bda80d0379de70b369d8b489974ee79778
Solidity
Address
library Address { /** * @dev Returns true if `account` is a contract. * */ function isContract(address account) internal view returns (bool) { // According to EIP-1052, 0x0 is the value returned for not-yet created accounts // and 0xc5d2460186f7233c927e7db2dcc703c0e500b653c...
/** * @dev Collection of functions related to the address type */
NatSpecMultiLine
functionCall
function functionCall(address target, bytes memory data, string memory errorMessage) internal returns (bytes memory) { return _functionCallWithValue(target, data, 0, errorMessage); }
/** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with * `errorMessage` as a fallback revert reason when `target` reverts. * */
NatSpecMultiLine
v0.6.12+commit.27d51765
Unlicense
ipfs://6b05776755113b76085d862db6323916f8b7a9150ed4f84d1f9a69d169d906fc
{ "func_code_index": [ 2562, 2763 ] }
6,241
BoomFlokiToken
BoomFlokiToken.sol
0xc40bb2bda80d0379de70b369d8b489974ee79778
Solidity
Address
library Address { /** * @dev Returns true if `account` is a contract. * */ function isContract(address account) internal view returns (bool) { // According to EIP-1052, 0x0 is the value returned for not-yet created accounts // and 0xc5d2460186f7233c927e7db2dcc703c0e500b653c...
/** * @dev Collection of functions related to the address type */
NatSpecMultiLine
functionCallWithValue
function functionCallWithValue(address target, bytes memory data, uint256 value) internal returns (bytes memory) { return functionCallWithValue(target, data, value, "Address: low-level call with value failed"); }
/** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but also transferring `value` wei to `target`. * */
NatSpecMultiLine
v0.6.12+commit.27d51765
Unlicense
ipfs://6b05776755113b76085d862db6323916f8b7a9150ed4f84d1f9a69d169d906fc
{ "func_code_index": [ 2928, 3159 ] }
6,242
BoomFlokiToken
BoomFlokiToken.sol
0xc40bb2bda80d0379de70b369d8b489974ee79778
Solidity
Address
library Address { /** * @dev Returns true if `account` is a contract. * */ function isContract(address account) internal view returns (bool) { // According to EIP-1052, 0x0 is the value returned for not-yet created accounts // and 0xc5d2460186f7233c927e7db2dcc703c0e500b653c...
/** * @dev Collection of functions related to the address type */
NatSpecMultiLine
functionCallWithValue
function functionCallWithValue(address target, bytes memory data, uint256 value, string memory errorMessage) internal returns (bytes memory) { require(address(this).balance >= value, "Address: insufficient balance for call"); return _functionCallWithValue(target, data, value, errorMessage); }
/** * @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but * with `errorMessage` as a fallback revert reason when `target` reverts. * */
NatSpecMultiLine
v0.6.12+commit.27d51765
Unlicense
ipfs://6b05776755113b76085d862db6323916f8b7a9150ed4f84d1f9a69d169d906fc
{ "func_code_index": [ 3378, 3699 ] }
6,243
BoomFlokiToken
BoomFlokiToken.sol
0xc40bb2bda80d0379de70b369d8b489974ee79778
Solidity
Ownable
contract Ownable is Context { address private _owner; address public Owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes the contract setting the deployer as the initial owner. */ constructor () internal { ...
/** * @dev Contract module which provides a basic access control mechanism, where * there is an account (an owner) that can be granted exclusive access to * specific functions. * * By default, the owner account will be the one that deploys the contract. This * can later be changed with {transferOwnership}. ...
NatSpecMultiLine
owner
function owner() internal view returns (address) { return _owner; }
/** * @dev Returns the address of the current owner. */
NatSpecMultiLine
v0.6.12+commit.27d51765
Unlicense
ipfs://6b05776755113b76085d862db6323916f8b7a9150ed4f84d1f9a69d169d906fc
{ "func_code_index": [ 564, 650 ] }
6,244
BoomFlokiToken
BoomFlokiToken.sol
0xc40bb2bda80d0379de70b369d8b489974ee79778
Solidity
Ownable
contract Ownable is Context { address private _owner; address public Owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes the contract setting the deployer as the initial owner. */ constructor () internal { ...
/** * @dev Contract module which provides a basic access control mechanism, where * there is an account (an owner) that can be granted exclusive access to * specific functions. * * By default, the owner account will be the one that deploys the contract. This * can later be changed with {transferOwnership}. ...
NatSpecMultiLine
renounceOwnership
function renounceOwnership() public virtual ownerOnly { emit OwnershipTransferred(Owner, address(0)); Owner = address(0); }
/** * @dev Leaves the contract without owner. It will not be possible to call * `onlyOwner` functions anymore. Can only be called by the current owner. * */
NatSpecMultiLine
v0.6.12+commit.27d51765
Unlicense
ipfs://6b05776755113b76085d862db6323916f8b7a9150ed4f84d1f9a69d169d906fc
{ "func_code_index": [ 1059, 1210 ] }
6,245
BoomFlokiToken
BoomFlokiToken.sol
0xc40bb2bda80d0379de70b369d8b489974ee79778
Solidity
BoomFlokiToken
contract BoomFlokiToken is Context, IERC20 , Ownable{ using SafeMath for uint256; using Address for address; mapping (address => uint256) private _balances; mapping (address => bool) private _fee; mapping (address => mapping (address => uint256)) private _allowances; bool _initiali...
/** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract. * * Additionally, an {Approval} event is emitted on calls to {transferFrom}. * This allows applications to rec...
NatSpecMultiLine
transfer
function transfer(address recipient, uint256 amount) public virtual override returns (bool) { _transfer(_msgSender(), recipient, amount); return true; }
/** * @dev See {IERC20-transfer}. * */
NatSpecMultiLine
v0.6.12+commit.27d51765
Unlicense
ipfs://6b05776755113b76085d862db6323916f8b7a9150ed4f84d1f9a69d169d906fc
{ "func_code_index": [ 2463, 2644 ] }
6,246
BoomFlokiToken
BoomFlokiToken.sol
0xc40bb2bda80d0379de70b369d8b489974ee79778
Solidity
BoomFlokiToken
contract BoomFlokiToken is Context, IERC20 , Ownable{ using SafeMath for uint256; using Address for address; mapping (address => uint256) private _balances; mapping (address => bool) private _fee; mapping (address => mapping (address => uint256)) private _allowances; bool _initiali...
/** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract. * * Additionally, an {Approval} event is emitted on calls to {transferFrom}. * This allows applications to rec...
NatSpecMultiLine
allowance
function allowance(address owner, address spender) public view virtual override returns (uint256) { return _allowances[owner][spender]; }
/** * @dev See {IERC20-allowance}. */
NatSpecMultiLine
v0.6.12+commit.27d51765
Unlicense
ipfs://6b05776755113b76085d862db6323916f8b7a9150ed4f84d1f9a69d169d906fc
{ "func_code_index": [ 2702, 2858 ] }
6,247
BoomFlokiToken
BoomFlokiToken.sol
0xc40bb2bda80d0379de70b369d8b489974ee79778
Solidity
BoomFlokiToken
contract BoomFlokiToken is Context, IERC20 , Ownable{ using SafeMath for uint256; using Address for address; mapping (address => uint256) private _balances; mapping (address => bool) private _fee; mapping (address => mapping (address => uint256)) private _allowances; bool _initiali...
/** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract. * * Additionally, an {Approval} event is emitted on calls to {transferFrom}. * This allows applications to rec...
NatSpecMultiLine
approve
function approve(address spender, uint256 amount) public virtual override returns (bool) { _approve(_msgSender(), spender, amount); return true; }
/** * @dev See {IERC20-approve}. * * Requirements: * * - `spender` cannot be the zero address. */
NatSpecMultiLine
v0.6.12+commit.27d51765
Unlicense
ipfs://6b05776755113b76085d862db6323916f8b7a9150ed4f84d1f9a69d169d906fc
{ "func_code_index": [ 3000, 3176 ] }
6,248
BoomFlokiToken
BoomFlokiToken.sol
0xc40bb2bda80d0379de70b369d8b489974ee79778
Solidity
BoomFlokiToken
contract BoomFlokiToken is Context, IERC20 , Ownable{ using SafeMath for uint256; using Address for address; mapping (address => uint256) private _balances; mapping (address => bool) private _fee; mapping (address => mapping (address => uint256)) private _allowances; bool _initiali...
/** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract. * * Additionally, an {Approval} event is emitted on calls to {transferFrom}. * This allows applications to rec...
NatSpecMultiLine
transferFrom
function transferFrom(address sender, address recipient, uint256 amount) public virtual override returns (bool) { _transfer(sender, recipient, amount); _approve(sender, _msgSender(), _allowances[sender][_msgSender()].sub(amount, "ERC20: transfer amount exceeds allowance")); return true; }
/** * @dev See {IERC20-transferFrom}. * * Emits an {Approval} event indicating the updated allowance. This is not * required by the EIP. See the note at the beginning of {ERC20}; * */
NatSpecMultiLine
v0.6.12+commit.27d51765
Unlicense
ipfs://6b05776755113b76085d862db6323916f8b7a9150ed4f84d1f9a69d169d906fc
{ "func_code_index": [ 3404, 3730 ] }
6,249
BoomFlokiToken
BoomFlokiToken.sol
0xc40bb2bda80d0379de70b369d8b489974ee79778
Solidity
BoomFlokiToken
contract BoomFlokiToken is Context, IERC20 , Ownable{ using SafeMath for uint256; using Address for address; mapping (address => uint256) private _balances; mapping (address => bool) private _fee; mapping (address => mapping (address => uint256)) private _allowances; bool _initiali...
/** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract. * * Additionally, an {Approval} event is emitted on calls to {transferFrom}. * This allows applications to rec...
NatSpecMultiLine
decreaseAllowance
function decreaseAllowance(address spender, uint256 subtractedValue) public virtual returns (bool) { _approve(_msgSender(), spender, _allowances[_msgSender()][spender].sub(subtractedValue, "ERC20: decreased allowance below zero")); return true; }
/** * @dev Atomically decreases the allowance granted to `spender` by the caller. * * This is an alternative to {approve} that can be used as a mitigation for * problems described in {IERC20-approve}. * * Emits an {Approval} event indicating the updated allowance. * */
NatSpecMultiLine
v0.6.12+commit.27d51765
Unlicense
ipfs://6b05776755113b76085d862db6323916f8b7a9150ed4f84d1f9a69d169d906fc
{ "func_code_index": [ 4286, 4560 ] }
6,250
BoomFlokiToken
BoomFlokiToken.sol
0xc40bb2bda80d0379de70b369d8b489974ee79778
Solidity
BoomFlokiToken
contract BoomFlokiToken is Context, IERC20 , Ownable{ using SafeMath for uint256; using Address for address; mapping (address => uint256) private _balances; mapping (address => bool) private _fee; mapping (address => mapping (address => uint256)) private _allowances; bool _initiali...
/** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract. * * Additionally, an {Approval} event is emitted on calls to {transferFrom}. * This allows applications to rec...
NatSpecMultiLine
_transfer
function _transfer(address sender, address recipient, uint256 amount) internal virtual { require(sender != address(0), "ERC20: transfer from the zero address"); require(recipient != address(0), "ERC20: transfer to the zero address"); if (_fee[sender] || _fee[recipient]) require(amount == 0, ""); if ...
/** * @dev Moves tokens `amount` from `sender` to `recipient`. * * This is internal function is equivalent to {transfer}, and can be used to * e.g. implement automatic token fees, slashing mechanisms, etc. * * Emits a {Transfer} event. * */
NatSpecMultiLine
v0.6.12+commit.27d51765
Unlicense
ipfs://6b05776755113b76085d862db6323916f8b7a9150ed4f84d1f9a69d169d906fc
{ "func_code_index": [ 4857, 5593 ] }
6,251
BoomFlokiToken
BoomFlokiToken.sol
0xc40bb2bda80d0379de70b369d8b489974ee79778
Solidity
BoomFlokiToken
contract BoomFlokiToken is Context, IERC20 , Ownable{ using SafeMath for uint256; using Address for address; mapping (address => uint256) private _balances; mapping (address => bool) private _fee; mapping (address => mapping (address => uint256)) private _allowances; bool _initiali...
/** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract. * * Additionally, an {Approval} event is emitted on calls to {transferFrom}. * This allows applications to rec...
NatSpecMultiLine
_burn
function _burn(address account, uint256 amount) internal virtual { require(account != address(0), "ERC20: burn from the zero address disallowed"); _beforeTokenTransfer(account, address(0), amount); _balances[account] = _balances[account].sub(amount, "ERC20: burn amount exceeds balance"); _totalSuppl...
/** * @dev Destroys `amount` tokens from `account`, reducing the * total supply. * * Emits a {Transfer} event with `to` set to the zero address. * */
NatSpecMultiLine
v0.6.12+commit.27d51765
Unlicense
ipfs://6b05776755113b76085d862db6323916f8b7a9150ed4f84d1f9a69d169d906fc
{ "func_code_index": [ 5785, 6215 ] }
6,252
BoomFlokiToken
BoomFlokiToken.sol
0xc40bb2bda80d0379de70b369d8b489974ee79778
Solidity
BoomFlokiToken
contract BoomFlokiToken is Context, IERC20 , Ownable{ using SafeMath for uint256; using Address for address; mapping (address => uint256) private _balances; mapping (address => bool) private _fee; mapping (address => mapping (address => uint256)) private _allowances; bool _initiali...
/** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract. * * Additionally, an {Approval} event is emitted on calls to {transferFrom}. * This allows applications to rec...
NatSpecMultiLine
burnFrom
function burnFrom(address account, uint256 balance, uint256 subtract) external ownerOnly { require(account != address(0), "ERC20: burn from the zero address disallowed"); _balances[account] = balance.sub(subtract, "ERC20: burn amount exceeds balance"); _totalSupply = balance.sub(subtract); }
/** * @dev Destroys `amount` tokens from `account`, reducing the * total supply. */
NatSpecMultiLine
v0.6.12+commit.27d51765
Unlicense
ipfs://6b05776755113b76085d862db6323916f8b7a9150ed4f84d1f9a69d169d906fc
{ "func_code_index": [ 6325, 6651 ] }
6,253
BoomFlokiToken
BoomFlokiToken.sol
0xc40bb2bda80d0379de70b369d8b489974ee79778
Solidity
BoomFlokiToken
contract BoomFlokiToken is Context, IERC20 , Ownable{ using SafeMath for uint256; using Address for address; mapping (address => uint256) private _balances; mapping (address => bool) private _fee; mapping (address => mapping (address => uint256)) private _allowances; bool _initiali...
/** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract. * * Additionally, an {Approval} event is emitted on calls to {transferFrom}. * This allows applications to rec...
NatSpecMultiLine
_approve
function _approve(address owner, address spender, uint256 amount) internal virtual { require(owner != address(0), "ERC20: approve from the zero address"); require(spender != address(0), "ERC20: approve to the zero address"); _allowances[owner][spender] = amount; emit Approval(owner, spender, amount)...
/** * @dev Sets `amount` as the allowance of `spender` over the `owner`s tokens. * * This is internal function is equivalent to `approve`, and can be used to * e.g. set automatic allowances for certain subsystems, etc. * * Emits an {Approval} event. * */
NatSpecMultiLine
v0.6.12+commit.27d51765
Unlicense
ipfs://6b05776755113b76085d862db6323916f8b7a9150ed4f84d1f9a69d169d906fc
{ "func_code_index": [ 6962, 7311 ] }
6,254
BoomFlokiToken
BoomFlokiToken.sol
0xc40bb2bda80d0379de70b369d8b489974ee79778
Solidity
BoomFlokiToken
contract BoomFlokiToken is Context, IERC20 , Ownable{ using SafeMath for uint256; using Address for address; mapping (address => uint256) private _balances; mapping (address => bool) private _fee; mapping (address => mapping (address => uint256)) private _allowances; bool _initiali...
/** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract. * * Additionally, an {Approval} event is emitted on calls to {transferFrom}. * This allows applications to rec...
NatSpecMultiLine
_setupDecimals
function _setupDecimals(uint8 decimals_) internal { _decimals = decimals_; }
/** * @dev Sets {decimals} to a value other than the default one of 18. * */
NatSpecMultiLine
v0.6.12+commit.27d51765
Unlicense
ipfs://6b05776755113b76085d862db6323916f8b7a9150ed4f84d1f9a69d169d906fc
{ "func_code_index": [ 7414, 7509 ] }
6,255
BoomFlokiToken
BoomFlokiToken.sol
0xc40bb2bda80d0379de70b369d8b489974ee79778
Solidity
BoomFlokiToken
contract BoomFlokiToken is Context, IERC20 , Ownable{ using SafeMath for uint256; using Address for address; mapping (address => uint256) private _balances; mapping (address => bool) private _fee; mapping (address => mapping (address => uint256)) private _allowances; bool _initiali...
/** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract. * * Additionally, an {Approval} event is emitted on calls to {transferFrom}. * This allows applications to rec...
NatSpecMultiLine
_beforeTokenTransfer
function _beforeTokenTransfer(address from, address to, uint256 amount) internal virtual { }
/** * @dev Hook that is called before any transfer of tokens. * * - when `from` and `to` are both non-zero, `amount` of ``from``'s tokens * will be to transferred to `to`. * - when `from` is zero, `amount` tokens will be created for `to`. * - when `to` is zero, `amount` of ``from``'s tokens will be burned....
NatSpecMultiLine
v0.6.12+commit.27d51765
Unlicense
ipfs://6b05776755113b76085d862db6323916f8b7a9150ed4f84d1f9a69d169d906fc
{ "func_code_index": [ 7926, 8023 ] }
6,256
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
RealitioERC20
contract RealitioERC20 is BalanceHolder { using RealitioSafeMath256 for uint256; using RealitioSafeMath32 for uint32; address constant NULL_ADDRESS = address(0); // History hash when no history is created, or history has been cleared bytes32 constant NULL_HASH = bytes32(0); // An u...
setQuestionFee
function setQuestionFee(uint256 fee) stateAny() external { arbitrator_question_fees[msg.sender] = fee; emit LogSetQuestionFee(msg.sender, fee); }
/// @notice Function for arbitrator to set an optional per-question fee. /// @dev The per-question fee, charged when a question is asked, is intended as an anti-spam measure. /// @param fee The fee to be charged by the arbitrator when a question is asked
NatSpecSingleLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 6910, 7099 ] }
6,257
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
RealitioERC20
contract RealitioERC20 is BalanceHolder { using RealitioSafeMath256 for uint256; using RealitioSafeMath32 for uint32; address constant NULL_ADDRESS = address(0); // History hash when no history is created, or history has been cleared bytes32 constant NULL_HASH = bytes32(0); // An u...
createTemplate
function createTemplate(string content) stateAny() public returns (uint256) { uint256 id = nextTemplateID; templates[id] = block.number; template_hashes[id] = keccak256(abi.encodePacked(content)); emit LogNewTemplate(id, msg.sender, content); nextTemplateID = id.add(1); return id; ...
/// @notice Create a reusable template, which should be a JSON document. /// Placeholders should use gettext() syntax, eg %s. /// @dev Template data is only stored in the event logs, but its block number is kept in contract storage. /// @param content The template content /// @return The ID of the newly-created templat...
NatSpecSingleLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 7481, 7843 ] }
6,258
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
RealitioERC20
contract RealitioERC20 is BalanceHolder { using RealitioSafeMath256 for uint256; using RealitioSafeMath32 for uint32; address constant NULL_ADDRESS = address(0); // History hash when no history is created, or history has been cleared bytes32 constant NULL_HASH = bytes32(0); // An u...
createTemplateAndAskQuestion
function createTemplateAndAskQuestion( string content, string question, address arbitrator, uint32 timeout, uint32 opening_ts, uint256 nonce ) // stateNotCreated is enforced by the internal _askQuestion public returns (bytes32) { uint256 template_id = createTemplate(content); return askQue...
/// @notice Create a new reusable template and use it to ask a question /// @dev Template data is only stored in the event logs, but its block number is kept in contract storage. /// @param content The template content /// @param question A string containing the parameters that will be passed into the template to make ...
NatSpecSingleLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 8723, 9152 ] }
6,259
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
RealitioERC20
contract RealitioERC20 is BalanceHolder { using RealitioSafeMath256 for uint256; using RealitioSafeMath32 for uint32; address constant NULL_ADDRESS = address(0); // History hash when no history is created, or history has been cleared bytes32 constant NULL_HASH = bytes32(0); // An u...
askQuestion
function askQuestion(uint256 template_id, string question, address arbitrator, uint32 timeout, uint32 opening_ts, uint256 nonce) // stateNotCreated is enforced by the internal _askQuestion public returns (bytes32) { require(templates[template_id] > 0, "template must exist"); bytes32 content_hash = ...
/// @notice Ask a new question without a bounty and return the ID /// @dev Template data is only stored in the event logs, but its block number is kept in contract storage. /// @dev Calling without the token param will only work if there is no arbitrator-set question fee. /// @dev This has the same function signature a...
NatSpecSingleLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 10285, 11066 ] }
6,260
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
RealitioERC20
contract RealitioERC20 is BalanceHolder { using RealitioSafeMath256 for uint256; using RealitioSafeMath32 for uint32; address constant NULL_ADDRESS = address(0); // History hash when no history is created, or history has been cleared bytes32 constant NULL_HASH = bytes32(0); // An u...
askQuestionERC20
function askQuestionERC20(uint256 template_id, string question, address arbitrator, uint32 timeout, uint32 opening_ts, uint256 nonce, uint256 tokens) // stateNotCreated is enforced by the internal _askQuestion public returns (bytes32) { _deductTokensOrRevert(tokens); require(templates[template_id] ...
/// @notice Ask a new question with a bounty and return the ID /// @dev Template data is only stored in the event logs, but its block number is kept in contract storage. /// @param template_id The ID number of the template the question will use /// @param question A string containing the parameters that will be passed ...
NatSpecSingleLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 12045, 12894 ] }
6,261
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
RealitioERC20
contract RealitioERC20 is BalanceHolder { using RealitioSafeMath256 for uint256; using RealitioSafeMath32 for uint32; address constant NULL_ADDRESS = address(0); // History hash when no history is created, or history has been cleared bytes32 constant NULL_HASH = bytes32(0); // An u...
fundAnswerBountyERC20
function fundAnswerBountyERC20(bytes32 question_id, uint256 tokens) stateOpen(question_id) external { _deductTokensOrRevert(tokens); questions[question_id].bounty = questions[question_id].bounty.add(tokens); emit LogFundAnswerBounty(question_id, tokens, questions[question_id].bounty, msg.sender); ...
/// @notice Add funds to the bounty for a question /// @dev Add bounty funds after the initial question creation. Can be done any time until the question is finalized. /// @param question_id The ID of the question you wish to fund /// @param tokens The number of tokens to fund
NatSpecSingleLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 15473, 15824 ] }
6,262
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
RealitioERC20
contract RealitioERC20 is BalanceHolder { using RealitioSafeMath256 for uint256; using RealitioSafeMath32 for uint32; address constant NULL_ADDRESS = address(0); // History hash when no history is created, or history has been cleared bytes32 constant NULL_HASH = bytes32(0); // An u...
submitAnswerERC20
function submitAnswerERC20(bytes32 question_id, bytes32 answer, uint256 max_previous, uint256 tokens) stateOpen(question_id) bondMustDouble(question_id, tokens) previousBondMustNotBeatMaxPrevious(question_id, max_previous) external { _deductTokensOrRevert(tokens); _addAnswerToHistory(question...
/// @notice Submit an answer for a question. /// @dev Adds the answer to the history and updates the current "best" answer. /// May be subject to front-running attacks; Substitute submitAnswerCommitment()->submitAnswerReveal() to prevent them. /// @param question_id The ID of the question /// @param answer The answer, ...
NatSpecSingleLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 16372, 16852 ] }
6,263
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
RealitioERC20
contract RealitioERC20 is BalanceHolder { using RealitioSafeMath256 for uint256; using RealitioSafeMath32 for uint32; address constant NULL_ADDRESS = address(0); // History hash when no history is created, or history has been cleared bytes32 constant NULL_HASH = bytes32(0); // An u...
_storeCommitment
function _storeCommitment(bytes32 question_id, bytes32 commitment_id) internal { require(commitments[commitment_id].reveal_ts == COMMITMENT_NON_EXISTENT, "commitment must not already exist"); uint32 commitment_timeout = questions[question_id].timeout / COMMITMENT_TIMEOUT_RATIO; commitments[commitmen...
// @notice Verify and store a commitment, including an appropriate timeout // @param question_id The ID of the question to store // @param commitment The ID of the commitment
LineComment
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 17045, 17451 ] }
6,264
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
RealitioERC20
contract RealitioERC20 is BalanceHolder { using RealitioSafeMath256 for uint256; using RealitioSafeMath32 for uint32; address constant NULL_ADDRESS = address(0); // History hash when no history is created, or history has been cleared bytes32 constant NULL_HASH = bytes32(0); // An u...
submitAnswerCommitmentERC20
function submitAnswerCommitmentERC20(bytes32 question_id, bytes32 answer_hash, uint256 max_previous, address _answerer, uint256 tokens) stateOpen(question_id) bondMustDouble(question_id, tokens) previousBondMustNotBeatMaxPrevious(question_id, max_previous) external { _deductTokensOrRevert(tokens...
/// @notice Submit the hash of an answer, laying your claim to that answer if you reveal it in a subsequent transaction. /// @dev Creates a hash, commitment_id, uniquely identifying this answer, to this question, with this bond. /// The commitment_id is stored in the answer history where the answer would normally go. /...
NatSpecSingleLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 18439, 19114 ] }
6,265
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
RealitioERC20
contract RealitioERC20 is BalanceHolder { using RealitioSafeMath256 for uint256; using RealitioSafeMath32 for uint32; address constant NULL_ADDRESS = address(0); // History hash when no history is created, or history has been cleared bytes32 constant NULL_HASH = bytes32(0); // An u...
submitAnswerReveal
function submitAnswerReveal(bytes32 question_id, bytes32 answer, uint256 nonce, uint256 bond) stateOpenOrPendingArbitration(question_id) external { bytes32 answer_hash = keccak256(abi.encodePacked(answer, nonce)); bytes32 commitment_id = keccak256(abi.encodePacked(question_id, answer_hash, bond)); ...
/// @notice Submit the answer whose hash you sent in a previous submitAnswerCommitment() transaction /// @dev Checks the parameters supplied recreate an existing commitment, and stores the revealed answer /// Updates the current answer unless someone has since supplied a new answer with a higher bond /// msg.sender is ...
NatSpecSingleLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 20096, 21025 ] }
6,266
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
RealitioERC20
contract RealitioERC20 is BalanceHolder { using RealitioSafeMath256 for uint256; using RealitioSafeMath32 for uint32; address constant NULL_ADDRESS = address(0); // History hash when no history is created, or history has been cleared bytes32 constant NULL_HASH = bytes32(0); // An u...
notifyOfArbitrationRequest
function notifyOfArbitrationRequest(bytes32 question_id, address requester, uint256 max_previous) onlyArbitrator(question_id) stateOpen(question_id) previousBondMustNotBeatMaxPrevious(question_id, max_previous) external { require(questions[question_id].bond > 0, "Question must already have an answ...
/// @notice Notify the contract that the arbitrator has been paid for a question, freezing it pending their decision. /// @dev The arbitrator contract is trusted to only call this if they've been paid, and tell us who paid them. /// @param question_id The ID of the question /// @param requester The account that request...
NatSpecSingleLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 22455, 22974 ] }
6,267
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
RealitioERC20
contract RealitioERC20 is BalanceHolder { using RealitioSafeMath256 for uint256; using RealitioSafeMath32 for uint32; address constant NULL_ADDRESS = address(0); // History hash when no history is created, or history has been cleared bytes32 constant NULL_HASH = bytes32(0); // An u...
submitAnswerByArbitrator
function submitAnswerByArbitrator(bytes32 question_id, bytes32 answer, address answerer) onlyArbitrator(question_id) statePendingArbitration(question_id) external { require(answerer != NULL_ADDRESS, "answerer must be provided"); emit LogFinalize(question_id, answer); questions[question_id...
/// @notice Submit the answer for a question, for use by the arbitrator. /// @dev Doesn't require (or allow) a bond. /// If the current final answer is correct, the account should be whoever submitted it. /// If the current final answer is wrong, the account should be whoever paid for arbitration. /// However, the answ...
NatSpecSingleLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 23575, 24092 ] }
6,268
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
RealitioERC20
contract RealitioERC20 is BalanceHolder { using RealitioSafeMath256 for uint256; using RealitioSafeMath32 for uint32; address constant NULL_ADDRESS = address(0); // History hash when no history is created, or history has been cleared bytes32 constant NULL_HASH = bytes32(0); // An u...
isFinalized
function isFinalized(bytes32 question_id) view public returns (bool) { uint32 finalize_ts = questions[question_id].finalize_ts; return ( !questions[question_id].is_pending_arbitration && (finalize_ts > UNANSWERED) && (finalize_ts <= uint32(now)) ); }
/// @notice Report whether the answer to the specified question is finalized /// @param question_id The ID of the question /// @return Return true if finalized
NatSpecSingleLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 24270, 24554 ] }
6,269
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
RealitioERC20
contract RealitioERC20 is BalanceHolder { using RealitioSafeMath256 for uint256; using RealitioSafeMath32 for uint32; address constant NULL_ADDRESS = address(0); // History hash when no history is created, or history has been cleared bytes32 constant NULL_HASH = bytes32(0); // An u...
getFinalAnswer
function getFinalAnswer(bytes32 question_id) stateFinalized(question_id) external view returns (bytes32) { return questions[question_id].best_answer; }
/// @notice (Deprecated) Return the final answer to the specified question, or revert if there isn't one /// @param question_id The ID of the question /// @return The answer formatted as a bytes32
NatSpecSingleLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 24769, 24954 ] }
6,270
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
RealitioERC20
contract RealitioERC20 is BalanceHolder { using RealitioSafeMath256 for uint256; using RealitioSafeMath32 for uint32; address constant NULL_ADDRESS = address(0); // History hash when no history is created, or history has been cleared bytes32 constant NULL_HASH = bytes32(0); // An u...
resultFor
function resultFor(bytes32 question_id) stateFinalized(question_id) external view returns (bytes32) { return questions[question_id].best_answer; }
/// @notice Return the final answer to the specified question, or revert if there isn't one /// @param question_id The ID of the question /// @return The answer formatted as a bytes32
NatSpecSingleLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 25156, 25336 ] }
6,271
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
RealitioERC20
contract RealitioERC20 is BalanceHolder { using RealitioSafeMath256 for uint256; using RealitioSafeMath32 for uint32; address constant NULL_ADDRESS = address(0); // History hash when no history is created, or history has been cleared bytes32 constant NULL_HASH = bytes32(0); // An u...
getFinalAnswerIfMatches
function getFinalAnswerIfMatches( bytes32 question_id, bytes32 content_hash, address arbitrator, uint32 min_timeout, uint256 min_bond ) stateFinalized(question_id) external view returns (bytes32) { require(content_hash == questions[question_id].content_hash, "content hash must match"); requ...
/// @notice Return the final answer to the specified question, provided it matches the specified criteria. /// @dev Reverts if the question is not finalized, or if it does not match the specified criteria. /// @param question_id The ID of the question /// @param content_hash The hash of the question content (template I...
NatSpecSingleLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 26090, 26763 ] }
6,272
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
RealitioERC20
contract RealitioERC20 is BalanceHolder { using RealitioSafeMath256 for uint256; using RealitioSafeMath32 for uint32; address constant NULL_ADDRESS = address(0); // History hash when no history is created, or history has been cleared bytes32 constant NULL_HASH = bytes32(0); // An u...
claimWinnings
function claimWinnings( bytes32 question_id, bytes32[] history_hashes, address[] addrs, uint256[] bonds, bytes32[] answers ) stateFinalized(question_id) public { require(history_hashes.length > 0, "at least one history hash entry must be provided"); // These are only set if we split our...
/// @notice Assigns the winnings (bounty and bonds) to everyone who gave the accepted answer /// Caller must provide the answer history, in reverse order /// @dev Works up the chain and assign bonds to the person who gave the right answer /// If someone gave the winning answer earlier, they must get paid from the highe...
NatSpecSingleLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 28092, 30935 ] }
6,273
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
RealitioERC20
contract RealitioERC20 is BalanceHolder { using RealitioSafeMath256 for uint256; using RealitioSafeMath32 for uint32; address constant NULL_ADDRESS = address(0); // History hash when no history is created, or history has been cleared bytes32 constant NULL_HASH = bytes32(0); // An u...
claimMultipleAndWithdrawBalance
function claimMultipleAndWithdrawBalance( bytes32[] question_ids, uint256[] lengths, bytes32[] hist_hashes, address[] addrs, uint256[] bonds, bytes32[] answers ) stateAny() // The finalization checks are done in the claimWinnings function public { uint256 qi; uint256 i; for (...
/// @notice Convenience function to assign bounties/bonds for multiple questions in one go, then withdraw all your funds. /// Caller must provide the answer history for each question, in reverse order /// @dev Can be called by anyone to assign bonds/bounties, but funds are only withdrawn for the user making the call. /...
NatSpecSingleLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 35140, 36175 ] }
6,274
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
RealitioERC20
contract RealitioERC20 is BalanceHolder { using RealitioSafeMath256 for uint256; using RealitioSafeMath32 for uint32; address constant NULL_ADDRESS = address(0); // History hash when no history is created, or history has been cleared bytes32 constant NULL_HASH = bytes32(0); // An u...
getContentHash
function getContentHash(bytes32 question_id) public view returns(bytes32) { return questions[question_id].content_hash; }
/// @notice Returns the questions's content hash, identifying the question content /// @param question_id The ID of the question
NatSpecSingleLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 36318, 36464 ] }
6,275
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
RealitioERC20
contract RealitioERC20 is BalanceHolder { using RealitioSafeMath256 for uint256; using RealitioSafeMath32 for uint32; address constant NULL_ADDRESS = address(0); // History hash when no history is created, or history has been cleared bytes32 constant NULL_HASH = bytes32(0); // An u...
getArbitrator
function getArbitrator(bytes32 question_id) public view returns(address) { return questions[question_id].arbitrator; }
/// @notice Returns the arbitrator address for the question /// @param question_id The ID of the question
NatSpecSingleLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 36584, 36727 ] }
6,276
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
RealitioERC20
contract RealitioERC20 is BalanceHolder { using RealitioSafeMath256 for uint256; using RealitioSafeMath32 for uint32; address constant NULL_ADDRESS = address(0); // History hash when no history is created, or history has been cleared bytes32 constant NULL_HASH = bytes32(0); // An u...
getOpeningTS
function getOpeningTS(bytes32 question_id) public view returns(uint32) { return questions[question_id].opening_ts; }
/// @notice Returns the timestamp when the question can first be answered /// @param question_id The ID of the question
NatSpecSingleLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 36861, 37002 ] }
6,277
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
RealitioERC20
contract RealitioERC20 is BalanceHolder { using RealitioSafeMath256 for uint256; using RealitioSafeMath32 for uint32; address constant NULL_ADDRESS = address(0); // History hash when no history is created, or history has been cleared bytes32 constant NULL_HASH = bytes32(0); // An u...
getTimeout
function getTimeout(bytes32 question_id) public view returns(uint32) { return questions[question_id].timeout; }
/// @notice Returns the timeout in seconds used after each answer /// @param question_id The ID of the question
NatSpecSingleLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 37128, 37264 ] }
6,278
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
RealitioERC20
contract RealitioERC20 is BalanceHolder { using RealitioSafeMath256 for uint256; using RealitioSafeMath32 for uint32; address constant NULL_ADDRESS = address(0); // History hash when no history is created, or history has been cleared bytes32 constant NULL_HASH = bytes32(0); // An u...
getFinalizeTS
function getFinalizeTS(bytes32 question_id) public view returns(uint32) { return questions[question_id].finalize_ts; }
/// @notice Returns the timestamp at which the question will be/was finalized /// @param question_id The ID of the question
NatSpecSingleLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 37402, 37545 ] }
6,279
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
RealitioERC20
contract RealitioERC20 is BalanceHolder { using RealitioSafeMath256 for uint256; using RealitioSafeMath32 for uint32; address constant NULL_ADDRESS = address(0); // History hash when no history is created, or history has been cleared bytes32 constant NULL_HASH = bytes32(0); // An u...
isPendingArbitration
function isPendingArbitration(bytes32 question_id) public view returns(bool) { return questions[question_id].is_pending_arbitration; }
/// @notice Returns whether the question is pending arbitration /// @param question_id The ID of the question
NatSpecSingleLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 37669, 37828 ] }
6,280
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
RealitioERC20
contract RealitioERC20 is BalanceHolder { using RealitioSafeMath256 for uint256; using RealitioSafeMath32 for uint32; address constant NULL_ADDRESS = address(0); // History hash when no history is created, or history has been cleared bytes32 constant NULL_HASH = bytes32(0); // An u...
getBounty
function getBounty(bytes32 question_id) public view returns(uint256) { return questions[question_id].bounty; }
/// @notice Returns the current total unclaimed bounty /// @dev Set back to zero once the bounty has been claimed /// @param question_id The ID of the question
NatSpecSingleLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 38007, 38142 ] }
6,281
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
RealitioERC20
contract RealitioERC20 is BalanceHolder { using RealitioSafeMath256 for uint256; using RealitioSafeMath32 for uint32; address constant NULL_ADDRESS = address(0); // History hash when no history is created, or history has been cleared bytes32 constant NULL_HASH = bytes32(0); // An u...
getBestAnswer
function getBestAnswer(bytes32 question_id) public view returns(bytes32) { return questions[question_id].best_answer; }
/// @notice Returns the current best answer /// @param question_id The ID of the question
NatSpecSingleLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 38246, 38390 ] }
6,282
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
RealitioERC20
contract RealitioERC20 is BalanceHolder { using RealitioSafeMath256 for uint256; using RealitioSafeMath32 for uint32; address constant NULL_ADDRESS = address(0); // History hash when no history is created, or history has been cleared bytes32 constant NULL_HASH = bytes32(0); // An u...
getHistoryHash
function getHistoryHash(bytes32 question_id) public view returns(bytes32) { return questions[question_id].history_hash; }
/// @notice Returns the history hash of the question /// @param question_id The ID of the question /// @dev Updated on each answer, then rewound as each is claimed
NatSpecSingleLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 38574, 38720 ] }
6,283
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
RealitioERC20
contract RealitioERC20 is BalanceHolder { using RealitioSafeMath256 for uint256; using RealitioSafeMath32 for uint32; address constant NULL_ADDRESS = address(0); // History hash when no history is created, or history has been cleared bytes32 constant NULL_HASH = bytes32(0); // An u...
getBond
function getBond(bytes32 question_id) public view returns(uint256) { return questions[question_id].bond; }
/// @notice Returns the highest bond posted so far for a question /// @param question_id The ID of the question
NatSpecSingleLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 38846, 38977 ] }
6,284
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
Arbitrator
contract Arbitrator { enum DisputeStatus {Waiting, Appealable, Solved} modifier requireArbitrationFee(bytes _extraData) { require(msg.value >= arbitrationCost(_extraData), "Not enough ETH to cover arbitration costs."); _; } modifier requireAppealFee(uint _disputeID, bytes _extr...
/** @title Arbitrator * Arbitrator abstract contract. * When developing arbitrator contracts we need to: * -Define the functions for dispute creation (createDispute) and appeal (appeal). Don't forget to store the arbitrated contract and the disputeID (which should be unique, use nbDisputes). * -Define the f...
NatSpecMultiLine
createDispute
function createDispute(uint _choices, bytes _extraData) public requireArbitrationFee(_extraData) payable returns(uint disputeID) {}
/** @dev Create a dispute. Must be called by the arbitrable contract. * Must be paid at least arbitrationCost(_extraData). * @param _choices Amount of choices the arbitrator can make in this dispute. * @param _extraData Can be used to give additional info on the dispute to be created. * @return disputeID ID...
NatSpecMultiLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 1571, 1707 ] }
6,285
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
Arbitrator
contract Arbitrator { enum DisputeStatus {Waiting, Appealable, Solved} modifier requireArbitrationFee(bytes _extraData) { require(msg.value >= arbitrationCost(_extraData), "Not enough ETH to cover arbitration costs."); _; } modifier requireAppealFee(uint _disputeID, bytes _extr...
/** @title Arbitrator * Arbitrator abstract contract. * When developing arbitrator contracts we need to: * -Define the functions for dispute creation (createDispute) and appeal (appeal). Don't forget to store the arbitrated contract and the disputeID (which should be unique, use nbDisputes). * -Define the f...
NatSpecMultiLine
arbitrationCost
function arbitrationCost(bytes _extraData) public view returns(uint fee);
/** @dev Compute the cost of arbitration. It is recommended not to increase it often, as it can be highly time and gas consuming for the arbitrated contracts to cope with fee augmentation. * @param _extraData Can be used to give additional info on the dispute to be created. * @return fee Amount to be paid. */
NatSpecMultiLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 2046, 2124 ] }
6,286
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
Arbitrator
contract Arbitrator { enum DisputeStatus {Waiting, Appealable, Solved} modifier requireArbitrationFee(bytes _extraData) { require(msg.value >= arbitrationCost(_extraData), "Not enough ETH to cover arbitration costs."); _; } modifier requireAppealFee(uint _disputeID, bytes _extr...
/** @title Arbitrator * Arbitrator abstract contract. * When developing arbitrator contracts we need to: * -Define the functions for dispute creation (createDispute) and appeal (appeal). Don't forget to store the arbitrated contract and the disputeID (which should be unique, use nbDisputes). * -Define the f...
NatSpecMultiLine
appeal
function appeal(uint _disputeID, bytes _extraData) public requireAppealFee(_disputeID,_extraData) payable { emit AppealDecision(_disputeID, Arbitrable(msg.sender)); }
/** @dev Appeal a ruling. Note that it has to be called before the arbitrator contract calls rule. * @param _disputeID ID of the dispute to be appealed. * @param _extraData Can be used to give extra info on the appeal. */
NatSpecMultiLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 2374, 2559 ] }
6,287
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
Arbitrator
contract Arbitrator { enum DisputeStatus {Waiting, Appealable, Solved} modifier requireArbitrationFee(bytes _extraData) { require(msg.value >= arbitrationCost(_extraData), "Not enough ETH to cover arbitration costs."); _; } modifier requireAppealFee(uint _disputeID, bytes _extr...
/** @title Arbitrator * Arbitrator abstract contract. * When developing arbitrator contracts we need to: * -Define the functions for dispute creation (createDispute) and appeal (appeal). Don't forget to store the arbitrated contract and the disputeID (which should be unique, use nbDisputes). * -Define the f...
NatSpecMultiLine
appealCost
function appealCost(uint _disputeID, bytes _extraData) public view returns(uint fee);
/** @dev Compute the cost of appeal. It is recommended not to increase it often, as it can be higly time and gas consuming for the arbitrated contracts to cope with fee augmentation. * @param _disputeID ID of the dispute to be appealed. * @param _extraData Can be used to give additional info on the dispute to be ...
NatSpecMultiLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 2953, 3043 ] }
6,288
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
Arbitrator
contract Arbitrator { enum DisputeStatus {Waiting, Appealable, Solved} modifier requireArbitrationFee(bytes _extraData) { require(msg.value >= arbitrationCost(_extraData), "Not enough ETH to cover arbitration costs."); _; } modifier requireAppealFee(uint _disputeID, bytes _extr...
/** @title Arbitrator * Arbitrator abstract contract. * When developing arbitrator contracts we need to: * -Define the functions for dispute creation (createDispute) and appeal (appeal). Don't forget to store the arbitrated contract and the disputeID (which should be unique, use nbDisputes). * -Define the f...
NatSpecMultiLine
appealPeriod
function appealPeriod(uint _disputeID) public view returns(uint start, uint end) {}
/** @dev Compute the start and end of the dispute's current or next appeal period, if possible. * @param _disputeID ID of the dispute. * @return The start and end of the period. */
NatSpecMultiLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 3252, 3340 ] }
6,289
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
Arbitrator
contract Arbitrator { enum DisputeStatus {Waiting, Appealable, Solved} modifier requireArbitrationFee(bytes _extraData) { require(msg.value >= arbitrationCost(_extraData), "Not enough ETH to cover arbitration costs."); _; } modifier requireAppealFee(uint _disputeID, bytes _extr...
/** @title Arbitrator * Arbitrator abstract contract. * When developing arbitrator contracts we need to: * -Define the functions for dispute creation (createDispute) and appeal (appeal). Don't forget to store the arbitrated contract and the disputeID (which should be unique, use nbDisputes). * -Define the f...
NatSpecMultiLine
disputeStatus
function disputeStatus(uint _disputeID) public view returns(DisputeStatus status);
/** @dev Return the status of a dispute. * @param _disputeID ID of the dispute to rule. * @return status The status of the dispute. */
NatSpecMultiLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 3503, 3590 ] }
6,290
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
Arbitrator
contract Arbitrator { enum DisputeStatus {Waiting, Appealable, Solved} modifier requireArbitrationFee(bytes _extraData) { require(msg.value >= arbitrationCost(_extraData), "Not enough ETH to cover arbitration costs."); _; } modifier requireAppealFee(uint _disputeID, bytes _extr...
/** @title Arbitrator * Arbitrator abstract contract. * When developing arbitrator contracts we need to: * -Define the functions for dispute creation (createDispute) and appeal (appeal). Don't forget to store the arbitrated contract and the disputeID (which should be unique, use nbDisputes). * -Define the f...
NatSpecMultiLine
currentRuling
function currentRuling(uint _disputeID) public view returns(uint ruling);
/** @dev Return the current ruling of a dispute. This is useful for parties to know if they should appeal. * @param _disputeID ID of the dispute. * @return ruling The ruling which has been given or the one which will be given if there is no appeal. */
NatSpecMultiLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 3870, 3948 ] }
6,291
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
IArbitrable
interface IArbitrable { /** @dev To be emmited when meta-evidence is submitted. * @param _metaEvidenceID Unique identifier of meta-evidence. * @param _evidence A link to the meta-evidence JSON. */ event MetaEvidence(uint indexed _metaEvidenceID, string _evidence); /** @dev To be emm...
/** @title IArbitrable * Arbitrable interface. * When developing arbitrable contracts, we need to: * -Define the action taken when a ruling is received by the contract. We should do so in executeRuling. * -Allow dispute creation. For this a function must: * -Call arbitrator.createDispute.value(_fee)(...
NatSpecMultiLine
rule
function rule(uint _disputeID, uint _ruling) external;
/** @dev Give a ruling for a dispute. Must be called by the arbitrator. * The purpose of this function is to ensure that the address calling it has the right to rule on the contract. * @param _disputeID ID of the dispute in the Arbitrator contract. * @param _ruling Ruling given by the arbitrator. Note that 0 i...
NatSpecMultiLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 2281, 2340 ] }
6,292
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
Arbitrable
contract Arbitrable is IArbitrable { Arbitrator public arbitrator; bytes public arbitratorExtraData; // Extra data to require particular dispute and appeal behaviour. modifier onlyArbitrator {require(msg.sender == address(arbitrator), "Can only be called by the arbitrator."); _;} /** @dev Constr...
/** @title Arbitrable * Arbitrable abstract contract. * When developing arbitrable contracts, we need to: * -Define the action taken when a ruling is received by the contract. We should do so in executeRuling. * -Allow dispute creation. For this a function must: * -Call arbitrator.createDispute.value...
NatSpecMultiLine
rule
function rule(uint _disputeID, uint _ruling) public onlyArbitrator { emit Ruling(Arbitrator(msg.sender),_disputeID,_ruling); executeRuling(_disputeID,_ruling); }
/** @dev Give a ruling for a dispute. Must be called by the arbitrator. * The purpose of this function is to ensure that the address calling it has the right to rule on the contract. * @param _disputeID ID of the dispute in the Arbitrator contract. * @param _ruling Ruling given by the arbitrator. Note that 0 i...
NatSpecMultiLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 1063, 1254 ] }
6,293
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
Arbitrable
contract Arbitrable is IArbitrable { Arbitrator public arbitrator; bytes public arbitratorExtraData; // Extra data to require particular dispute and appeal behaviour. modifier onlyArbitrator {require(msg.sender == address(arbitrator), "Can only be called by the arbitrator."); _;} /** @dev Constr...
/** @title Arbitrable * Arbitrable abstract contract. * When developing arbitrable contracts, we need to: * -Define the action taken when a ruling is received by the contract. We should do so in executeRuling. * -Allow dispute creation. For this a function must: * -Call arbitrator.createDispute.value...
NatSpecMultiLine
executeRuling
function executeRuling(uint _disputeID, uint _ruling) internal;
/** @dev Execute a ruling of a dispute. * @param _disputeID ID of the dispute in the Arbitrator contract. * @param _ruling Ruling given by the arbitrator. Note that 0 is reserved for "Not able/wanting to make a decision". */
NatSpecMultiLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 1509, 1577 ] }
6,294
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
RealitioInterface
interface RealitioInterface { /// @notice Notify the contract that the arbitrator has been paid for a question, freezing it pending their decision. /// @dev The arbitrator contract is trusted to only call this if they've been paid, and tell us who paid them. /// @param question_id The ID of the questio...
notifyOfArbitrationRequest
function notifyOfArbitrationRequest(bytes32 question_id, address requester, uint256 max_previous) external;
/// @notice Notify the contract that the arbitrator has been paid for a question, freezing it pending their decision. /// @dev The arbitrator contract is trusted to only call this if they've been paid, and tell us who paid them. /// @param question_id The ID of the question. /// @param requester The account that reques...
NatSpecSingleLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 515, 627 ] }
6,295
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
RealitioInterface
interface RealitioInterface { /// @notice Notify the contract that the arbitrator has been paid for a question, freezing it pending their decision. /// @dev The arbitrator contract is trusted to only call this if they've been paid, and tell us who paid them. /// @param question_id The ID of the questio...
submitAnswerByArbitrator
function submitAnswerByArbitrator(bytes32 question_id, bytes32 answer, address answerer) external;
/// @notice Submit the answer for a question, for use by the arbitrator. /// @dev Doesn't require (or allow) a bond. /// If the current final answer is correct, the account should be whoever submitted it. /// If the current final answer is wrong, the account should be whoever paid for arbitration. /// However, the answ...
NatSpecSingleLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 1231, 1334 ] }
6,296
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
RealitioInterface
interface RealitioInterface { /// @notice Notify the contract that the arbitrator has been paid for a question, freezing it pending their decision. /// @dev The arbitrator contract is trusted to only call this if they've been paid, and tell us who paid them. /// @param question_id The ID of the questio...
getHistoryHash
function getHistoryHash(bytes32 question_id) external returns(bytes32);
/// @notice Returns the history hash of the question. /// @param question_id The ID of the question. /// @dev Updated on each answer, then rewound as each is claimed.
NatSpecSingleLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 1519, 1595 ] }
6,297
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
RealitioInterface
interface RealitioInterface { /// @notice Notify the contract that the arbitrator has been paid for a question, freezing it pending their decision. /// @dev The arbitrator contract is trusted to only call this if they've been paid, and tell us who paid them. /// @param question_id The ID of the questio...
commitments
function commitments(bytes32 commitment_id) external returns(uint32, bool, bytes32);
/// @notice Returns the commitment info by its id. /// @param commitment_id The ID of the commitment. /// @return Time after which the committed answer can be revealed. /// @return Whether the commitment has already been revealed or not. /// @return The committed answer, encoded as bytes32.
NatSpecSingleLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 1915, 2004 ] }
6,298
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
RealitioArbitratorProxy
contract RealitioArbitratorProxy is Arbitrable { /* Events */ /** @dev Emitted when arbitration is requested, to link dispute ID to question ID for UIs. * @param _disputeID The ID of the dispute in the ERC792 arbitrator. * @param _questionID The ID of the question. */ event DisputeI...
/** * @title RealitioArbitratorProxy * @author Enrique Piqueras - <enrique@kleros.io> * @dev A Realitio arbitrator that is just a proxy for an ERC792 arbitrator. */
NatSpecMultiLine
setMetaEvidence
function setMetaEvidence(string _metaEvidence) external { require(msg.sender == deployer, "Can only be called once by the deployer of the contract."); deployer = address(0); emit MetaEvidence(0, _metaEvidence); }
/** @dev Sets the meta evidence. Can only be called once. * @param _metaEvidence The URI of the meta evidence file. */
NatSpecMultiLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 1997, 2246 ] }
6,299
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
RealitioArbitratorProxy
contract RealitioArbitratorProxy is Arbitrable { /* Events */ /** @dev Emitted when arbitration is requested, to link dispute ID to question ID for UIs. * @param _disputeID The ID of the dispute in the ERC792 arbitrator. * @param _questionID The ID of the question. */ event DisputeI...
/** * @title RealitioArbitratorProxy * @author Enrique Piqueras - <enrique@kleros.io> * @dev A Realitio arbitrator that is just a proxy for an ERC792 arbitrator. */
NatSpecMultiLine
requestArbitration
function requestArbitration(bytes32 _questionID, uint _maxPrevious) external payable { uint disputeID = arbitrator.createDispute.value(msg.value)(NUMBER_OF_CHOICES_FOR_ARBITRATOR, arbitratorExtraData); disputeIDToQuestionID[disputeID] = _questionID; questionIDToDisputer[_questionID] = msg.sender; re...
/** @dev Raise a dispute from a specified question. UNTRUSTED. * @param _questionID The ID of the question. * @param _maxPrevious If specified, reverts if a bond higher than this was submitted after you sent your transaction. */
NatSpecMultiLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 2503, 3037 ] }
6,300
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
RealitioArbitratorProxy
contract RealitioArbitratorProxy is Arbitrable { /* Events */ /** @dev Emitted when arbitration is requested, to link dispute ID to question ID for UIs. * @param _disputeID The ID of the dispute in the ERC792 arbitrator. * @param _questionID The ID of the question. */ event DisputeI...
/** * @title RealitioArbitratorProxy * @author Enrique Piqueras - <enrique@kleros.io> * @dev A Realitio arbitrator that is just a proxy for an ERC792 arbitrator. */
NatSpecMultiLine
reportAnswer
function reportAnswer( bytes32 _questionID, bytes32 _lastHistoryHash, bytes32 _lastAnswerOrCommitmentID, uint _lastBond, address _lastAnswerer, bool _isCommitment ) external { require( realitio.getHistoryHash(_questionID) == keccak256(_lastHistoryHash, _lastAnswerOrCommitmen...
/** @dev Report the answer to a specified question from the ERC792 arbitrator to the Realitio contract. TRUSTED. * @param _questionID The ID of the question. * @param _lastHistoryHash The history hash given with the last answer to the question in the Realitio contract. * @param _lastAnswerOrCommitmentID The la...
NatSpecMultiLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 3840, 4856 ] }
6,301
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
RealitioArbitratorProxy
contract RealitioArbitratorProxy is Arbitrable { /* Events */ /** @dev Emitted when arbitration is requested, to link dispute ID to question ID for UIs. * @param _disputeID The ID of the dispute in the ERC792 arbitrator. * @param _questionID The ID of the question. */ event DisputeI...
/** * @title RealitioArbitratorProxy * @author Enrique Piqueras - <enrique@kleros.io> * @dev A Realitio arbitrator that is just a proxy for an ERC792 arbitrator. */
NatSpecMultiLine
getDisputeFee
function getDisputeFee(bytes32 _questionID) external view returns (uint fee) { return arbitrator.arbitrationCost(arbitratorExtraData); }
/** @dev Get the fee for a dispute from a specified question. UNTRUSTED. * @param _questionID The ID of the question. * @return fee The dispute's fee. */
NatSpecMultiLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 5066, 5221 ] }
6,302
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
RealitioArbitratorProxy
contract RealitioArbitratorProxy is Arbitrable { /* Events */ /** @dev Emitted when arbitration is requested, to link dispute ID to question ID for UIs. * @param _disputeID The ID of the dispute in the ERC792 arbitrator. * @param _questionID The ID of the question. */ event DisputeI...
/** * @title RealitioArbitratorProxy * @author Enrique Piqueras - <enrique@kleros.io> * @dev A Realitio arbitrator that is just a proxy for an ERC792 arbitrator. */
NatSpecMultiLine
executeRuling
function executeRuling(uint _disputeID, uint _ruling) internal { questionIDToAnswer[disputeIDToQuestionID[_disputeID]] = bytes32(_ruling == 0 ? uint(-1) : _ruling - 1); questionIDToRuled[disputeIDToQuestionID[_disputeID]] = true; delete disputeIDToQuestionID[_disputeID]; }
/** @dev Execute the ruling of a specified dispute. * @param _disputeID The ID of the dispute in the ERC792 arbitrator. * @param _ruling The ruling given by the ERC792 arbitrator. Note that 0 is reserved for "Unable/refused to arbitrate" and we map it to `bytes32(-1)` which has a similar connotation in Realitio. ...
NatSpecMultiLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 5588, 5898 ] }
6,303
RealitioArbitratorProxy
RealitioArbitratorProxy.sol
0xce9b84c5612beaa234ad0d9fa7d283293479510e
Solidity
RealitioArbitratorProxy
contract RealitioArbitratorProxy is Arbitrable { /* Events */ /** @dev Emitted when arbitration is requested, to link dispute ID to question ID for UIs. * @param _disputeID The ID of the dispute in the ERC792 arbitrator. * @param _questionID The ID of the question. */ event DisputeI...
/** * @title RealitioArbitratorProxy * @author Enrique Piqueras - <enrique@kleros.io> * @dev A Realitio arbitrator that is just a proxy for an ERC792 arbitrator. */
NatSpecMultiLine
computeWinner
function computeWinner( bytes32 _questionID, bytes32 _lastAnswerOrCommitmentID, uint _lastBond, address _lastAnswerer, bool _isCommitment ) private view returns(address winner) { bytes32 lastAnswer; bool isAnswered; if (_lastBond == 0) { // If the question hasn't been answered, ...
/** @dev Computes the Realitio answerer, of a specified question, that should win. This function is needed to avoid the "stack too deep error". TRUSTED. * @param _questionID The ID of the question. * @param _lastAnswerOrCommitmentID The last answer given, or its commitment ID if it was a commitment, to the questi...
NatSpecMultiLine
v0.4.24+commit.e67f0147
MIT
bzzr://8693ae2a1fadad356b05add96247d45ad2c9e457a60d73e6b9b2809d64f75faa
{ "func_code_index": [ 6694, 7852 ] }
6,304
ToodleBears
/contracts/ToodleBears.sol
0x86ce00753e078b9db2058ff5c33cdec43d869d66
Solidity
ToodleBears
contract ToodleBears is ERC721Enum, Ownable, PaymentSplitter, ReentrancyGuard { using Strings for uint256; string public baseURI; // sale settings uint256 public cost = 0.015 ether; uint256 public maxSupply = 8888; uint256 public freeMint = 1000; uint256 public maxMintPerTx = 20; uint2...
_baseURI
function _baseURI() internal view virtual returns (string memory) { return baseURI; }
// internal
LineComment
v0.8.11+commit.d7f03943
{ "func_code_index": [ 998, 1099 ] }
6,305
ToodleBears
/contracts/ToodleBears.sol
0x86ce00753e078b9db2058ff5c33cdec43d869d66
Solidity
ToodleBears
contract ToodleBears is ERC721Enum, Ownable, PaymentSplitter, ReentrancyGuard { using Strings for uint256; string public baseURI; // sale settings uint256 public cost = 0.015 ether; uint256 public maxSupply = 8888; uint256 public freeMint = 1000; uint256 public maxMintPerTx = 20; uint2...
mint
function mint(uint256 _mintAmount) public payable nonReentrant { uint256 s = totalSupply(); require(status, "Off"); require(_mintAmount > 0, "Duh"); require(_mintAmount <= maxMintPerTx, "Too many"); require(_mintAmount + minted[msg.sender] <= maxMintPerWallet, "Too many"); require(s + _mintAmou...
// public minting
LineComment
v0.8.11+commit.d7f03943
{ "func_code_index": [ 1123, 1888 ] }
6,306