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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
CriptaliaRewards | CriptaliaRewards.sol | 0x2c821a3ce3b5c0a471862eb63a2ef99a4d285d43 | Solidity | CriptaliaRewards | contract CriptaliaRewards 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.19+commit.c4cbbb05 | bzzr://8aa82eb5fe2ca991432d5ab5fda049a82fadf2c17c6a727dbc5bb442ea49e4de | {
"func_code_index": [
4944,
5003
]
} | 1,207 | ||
CriptaliaRewards | CriptaliaRewards.sol | 0x2c821a3ce3b5c0a471862eb63a2ef99a4d285d43 | Solidity | CriptaliaRewards | contract CriptaliaRewards 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.19+commit.c4cbbb05 | bzzr://8aa82eb5fe2ca991432d5ab5fda049a82fadf2c17c6a727dbc5bb442ea49e4de | {
"func_code_index": [
5236,
5425
]
} | 1,208 | |
KREEP | KREEP.sol | 0xbd9c92490b7e9444951fe86af90b6e54ab95cb16 | Solidity | IERC20 | interface IERC20 {
function totalSupply() external view returns (uint256);
/**
* @dev Returns the amount of tokens owned by `account`.
*/
function balanceOf(address account) external view returns (uint256);
/**
* @dev Moves `amount` tokens from the caller's account to `recipi... | balanceOf | function balanceOf(address account) external view returns (uint256);
| /**
* @dev Returns the amount of tokens owned by `account`.
*/ | NatSpecMultiLine | v0.6.12+commit.27d51765 | None | ipfs://39a71624c52ee018a303c30d9b86c3b7498d4c8dc13424b42bbf95fb353b3cea | {
"func_code_index": [
165,
238
]
} | 1,209 | ||
KREEP | KREEP.sol | 0xbd9c92490b7e9444951fe86af90b6e54ab95cb16 | Solidity | IERC20 | interface IERC20 {
function totalSupply() external view returns (uint256);
/**
* @dev Returns the amount of tokens owned by `account`.
*/
function balanceOf(address account) external view returns (uint256);
/**
* @dev Moves `amount` tokens from the caller's account to `recipi... | transfer | function transfer(address recipient, uint256 amount) external returns (bool);
| /**
* @dev Moves `amount` tokens from the caller's account to `recipient`.
*
* Returns a boolean value indicating whether the operation succeeded.
*
* Emits a {Transfer} event.
*/ | NatSpecMultiLine | v0.6.12+commit.27d51765 | None | ipfs://39a71624c52ee018a303c30d9b86c3b7498d4c8dc13424b42bbf95fb353b3cea | {
"func_code_index": [
462,
544
]
} | 1,210 | ||
KREEP | KREEP.sol | 0xbd9c92490b7e9444951fe86af90b6e54ab95cb16 | Solidity | IERC20 | interface IERC20 {
function totalSupply() external view returns (uint256);
/**
* @dev Returns the amount of tokens owned by `account`.
*/
function balanceOf(address account) external view returns (uint256);
/**
* @dev Moves `amount` tokens from the caller's account to `recipi... | 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 | None | ipfs://39a71624c52ee018a303c30d9b86c3b7498d4c8dc13424b42bbf95fb353b3cea | {
"func_code_index": [
823,
911
]
} | 1,211 | ||
KREEP | KREEP.sol | 0xbd9c92490b7e9444951fe86af90b6e54ab95cb16 | Solidity | IERC20 | interface IERC20 {
function totalSupply() external view returns (uint256);
/**
* @dev Returns the amount of tokens owned by `account`.
*/
function balanceOf(address account) external view returns (uint256);
/**
* @dev Moves `amount` tokens from the caller's account to `recipi... | 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.
*
* IMPORTANT: Beware that changing an allowance with this method brings the risk
* that someone may use both the old and the new allowance by unfortunate
... | NatSpecMultiLine | v0.6.12+commit.27d51765 | None | ipfs://39a71624c52ee018a303c30d9b86c3b7498d4c8dc13424b42bbf95fb353b3cea | {
"func_code_index": [
1575,
1654
]
} | 1,212 | ||
KREEP | KREEP.sol | 0xbd9c92490b7e9444951fe86af90b6e54ab95cb16 | Solidity | IERC20 | interface IERC20 {
function totalSupply() external view returns (uint256);
/**
* @dev Returns the amount of tokens owned by `account`.
*/
function balanceOf(address account) external view returns (uint256);
/**
* @dev Moves `amount` tokens from the caller's account to `recipi... | 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.
*
* Returns a boolean value indicating whether the operation succeeded.
*
* Emits a {Transfer} event.
*/ | NatSpecMultiLine | v0.6.12+commit.27d51765 | None | ipfs://39a71624c52ee018a303c30d9b86c3b7498d4c8dc13424b42bbf95fb353b3cea | {
"func_code_index": [
1967,
2069
]
} | 1,213 | ||
KREEP | KREEP.sol | 0xbd9c92490b7e9444951fe86af90b6e54ab95cb16 | Solidity | SafeMath | library SafeMath {
/**
* @dev Returns the addition of two unsigned integers, reverting on
* overflow.
*
* Counterpart to Solidity's `+` operator.
*
* Requirements:
*
* - Addition cannot overflow.
*/
function add(uint256 a, uint256 b) internal pure returns ... | /**
* @dev Wrappers over Solidity's arithmetic operations with added overflow
* checks.
*
* Arithmetic operations in Solidity wrap on overflow. This can easily result
* in bugs, because programmers usually assume that an overflow raises an
* error, which is the standard behavior in high level programming la... | 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.
*
* Requirements:
*
* - Addition cannot overflow.
*/ | NatSpecMultiLine | v0.6.12+commit.27d51765 | None | ipfs://39a71624c52ee018a303c30d9b86c3b7498d4c8dc13424b42bbf95fb353b3cea | {
"func_code_index": [
259,
445
]
} | 1,214 |
KREEP | KREEP.sol | 0xbd9c92490b7e9444951fe86af90b6e54ab95cb16 | Solidity | SafeMath | library SafeMath {
/**
* @dev Returns the addition of two unsigned integers, reverting on
* overflow.
*
* Counterpart to Solidity's `+` operator.
*
* Requirements:
*
* - Addition cannot overflow.
*/
function add(uint256 a, uint256 b) internal pure returns ... | /**
* @dev Wrappers over Solidity's arithmetic operations with added overflow
* checks.
*
* Arithmetic operations in Solidity wrap on overflow. This can easily result
* in bugs, because programmers usually assume that an overflow raises an
* error, which is the standard behavior in high level programming la... | 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.
*
* Requirements:
*
* - Subtraction cannot overflow.
*/ | NatSpecMultiLine | v0.6.12+commit.27d51765 | None | ipfs://39a71624c52ee018a303c30d9b86c3b7498d4c8dc13424b42bbf95fb353b3cea | {
"func_code_index": [
723,
864
]
} | 1,215 |
KREEP | KREEP.sol | 0xbd9c92490b7e9444951fe86af90b6e54ab95cb16 | Solidity | SafeMath | library SafeMath {
/**
* @dev Returns the addition of two unsigned integers, reverting on
* overflow.
*
* Counterpart to Solidity's `+` operator.
*
* Requirements:
*
* - Addition cannot overflow.
*/
function add(uint256 a, uint256 b) internal pure returns ... | /**
* @dev Wrappers over Solidity's arithmetic operations with added overflow
* checks.
*
* Arithmetic operations in Solidity wrap on overflow. This can easily result
* in bugs, because programmers usually assume that an overflow raises an
* error, which is the standard behavior in high level programming la... | 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.
*
* Requirements:
*
* - Subtraction cannot overflow.
*/ | NatSpecMultiLine | v0.6.12+commit.27d51765 | None | ipfs://39a71624c52ee018a303c30d9b86c3b7498d4c8dc13424b42bbf95fb353b3cea | {
"func_code_index": [
1162,
1359
]
} | 1,216 |
KREEP | KREEP.sol | 0xbd9c92490b7e9444951fe86af90b6e54ab95cb16 | Solidity | SafeMath | library SafeMath {
/**
* @dev Returns the addition of two unsigned integers, reverting on
* overflow.
*
* Counterpart to Solidity's `+` operator.
*
* Requirements:
*
* - Addition cannot overflow.
*/
function add(uint256 a, uint256 b) internal pure returns ... | /**
* @dev Wrappers over Solidity's arithmetic operations with added overflow
* checks.
*
* Arithmetic operations in Solidity wrap on overflow. This can easily result
* in bugs, because programmers usually assume that an overflow raises an
* error, which is the standard behavior in high level programming la... | 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.
*
* Requirements:
*
* - Multiplication cannot overflow.
*/ | NatSpecMultiLine | v0.6.12+commit.27d51765 | None | ipfs://39a71624c52ee018a303c30d9b86c3b7498d4c8dc13424b42bbf95fb353b3cea | {
"func_code_index": [
1613,
2089
]
} | 1,217 |
KREEP | KREEP.sol | 0xbd9c92490b7e9444951fe86af90b6e54ab95cb16 | Solidity | SafeMath | library SafeMath {
/**
* @dev Returns the addition of two unsigned integers, reverting on
* overflow.
*
* Counterpart to Solidity's `+` operator.
*
* Requirements:
*
* - Addition cannot overflow.
*/
function add(uint256 a, uint256 b) internal pure returns ... | /**
* @dev Wrappers over Solidity's arithmetic operations with added overflow
* checks.
*
* Arithmetic operations in Solidity wrap on overflow. This can easily result
* in bugs, because programmers usually assume that an overflow raises an
* error, which is the standard behavior in high level programming la... | 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 | None | ipfs://39a71624c52ee018a303c30d9b86c3b7498d4c8dc13424b42bbf95fb353b3cea | {
"func_code_index": [
2560,
2697
]
} | 1,218 |
KREEP | KREEP.sol | 0xbd9c92490b7e9444951fe86af90b6e54ab95cb16 | Solidity | SafeMath | library SafeMath {
/**
* @dev Returns the addition of two unsigned integers, reverting on
* overflow.
*
* Counterpart to Solidity's `+` operator.
*
* Requirements:
*
* - Addition cannot overflow.
*/
function add(uint256 a, uint256 b) internal pure returns ... | /**
* @dev Wrappers over Solidity's arithmetic operations with added overflow
* checks.
*
* Arithmetic operations in Solidity wrap on overflow. This can easily result
* in bugs, because programmers usually assume that an overflow raises an
* error, which is the standard behavior in high level programming la... | 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 | None | ipfs://39a71624c52ee018a303c30d9b86c3b7498d4c8dc13424b42bbf95fb353b3cea | {
"func_code_index": [
3188,
3471
]
} | 1,219 |
KREEP | KREEP.sol | 0xbd9c92490b7e9444951fe86af90b6e54ab95cb16 | Solidity | SafeMath | library SafeMath {
/**
* @dev Returns the addition of two unsigned integers, reverting on
* overflow.
*
* Counterpart to Solidity's `+` operator.
*
* Requirements:
*
* - Addition cannot overflow.
*/
function add(uint256 a, uint256 b) internal pure returns ... | /**
* @dev Wrappers over Solidity's arithmetic operations with added overflow
* checks.
*
* Arithmetic operations in Solidity wrap on overflow. This can easily result
* in bugs, because programmers usually assume that an overflow raises an
* error, which is the standard behavior in high level programming la... | 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 | None | ipfs://39a71624c52ee018a303c30d9b86c3b7498d4c8dc13424b42bbf95fb353b3cea | {
"func_code_index": [
3931,
4066
]
} | 1,220 |
KREEP | KREEP.sol | 0xbd9c92490b7e9444951fe86af90b6e54ab95cb16 | Solidity | SafeMath | library SafeMath {
/**
* @dev Returns the addition of two unsigned integers, reverting on
* overflow.
*
* Counterpart to Solidity's `+` operator.
*
* Requirements:
*
* - Addition cannot overflow.
*/
function add(uint256 a, uint256 b) internal pure returns ... | /**
* @dev Wrappers over Solidity's arithmetic operations with added overflow
* checks.
*
* Arithmetic operations in Solidity wrap on overflow. This can easily result
* in bugs, because programmers usually assume that an overflow raises an
* error, which is the standard behavior in high level programming la... | 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 | None | ipfs://39a71624c52ee018a303c30d9b86c3b7498d4c8dc13424b42bbf95fb353b3cea | {
"func_code_index": [
4546,
4717
]
} | 1,221 |
KREEP | KREEP.sol | 0xbd9c92490b7e9444951fe86af90b6e54ab95cb16 | Solidity | Address | library Address {
/**
* @dev Returns true if `account` is a contract.
*
* [IMPORTANT]
* ====
* It is unsafe to assume that an address for which this function returns
* false is an externally-owned account (EOA) and not a contract.
*
* Among others, `isContract` will ... | /**
* @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.
*
* [IMPORTANT]
* ====
* It is unsafe to assume that an address for which this function returns
* false is an externally-owned account (EOA) and not a contract.
*
* Among others, `isContract` will return false for the following
* types of addresses:
... | NatSpecMultiLine | v0.6.12+commit.27d51765 | None | ipfs://39a71624c52ee018a303c30d9b86c3b7498d4c8dc13424b42bbf95fb353b3cea | {
"func_code_index": [
606,
1230
]
} | 1,222 |
KREEP | KREEP.sol | 0xbd9c92490b7e9444951fe86af90b6e54ab95cb16 | Solidity | Address | library Address {
/**
* @dev Returns true if `account` is a contract.
*
* [IMPORTANT]
* ====
* It is unsafe to assume that an address for which this function returns
* false is an externally-owned account (EOA) and not a contract.
*
* Among others, `isContract` will ... | /**
* @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 | None | ipfs://39a71624c52ee018a303c30d9b86c3b7498d4c8dc13424b42bbf95fb353b3cea | {
"func_code_index": [
2160,
2562
]
} | 1,223 |
KREEP | KREEP.sol | 0xbd9c92490b7e9444951fe86af90b6e54ab95cb16 | Solidity | Address | library Address {
/**
* @dev Returns true if `account` is a contract.
*
* [IMPORTANT]
* ====
* It is unsafe to assume that an address for which this function returns
* false is an externally-owned account (EOA) and not a contract.
*
* Among others, `isContract` will ... | /**
* @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 | None | ipfs://39a71624c52ee018a303c30d9b86c3b7498d4c8dc13424b42bbf95fb353b3cea | {
"func_code_index": [
3318,
3496
]
} | 1,224 |
KREEP | KREEP.sol | 0xbd9c92490b7e9444951fe86af90b6e54ab95cb16 | Solidity | Address | library Address {
/**
* @dev Returns true if `account` is a contract.
*
* [IMPORTANT]
* ====
* It is unsafe to assume that an address for which this function returns
* false is an externally-owned account (EOA) and not a contract.
*
* Among others, `isContract` will ... | /**
* @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.
*
* _Available since v3.1._
*/ | NatSpecMultiLine | v0.6.12+commit.27d51765 | None | ipfs://39a71624c52ee018a303c30d9b86c3b7498d4c8dc13424b42bbf95fb353b3cea | {
"func_code_index": [
3721,
3922
]
} | 1,225 |
KREEP | KREEP.sol | 0xbd9c92490b7e9444951fe86af90b6e54ab95cb16 | Solidity | Address | library Address {
/**
* @dev Returns true if `account` is a contract.
*
* [IMPORTANT]
* ====
* It is unsafe to assume that an address for which this function returns
* false is an externally-owned account (EOA) and not a contract.
*
* Among others, `isContract` will ... | /**
* @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`.
*
* Requirements:
*
* - the calling contract must have an ETH balance of at least `value`.
* - the called Solidity function must be `payable`.
*
* _Available since v3.1._
*... | NatSpecMultiLine | v0.6.12+commit.27d51765 | None | ipfs://39a71624c52ee018a303c30d9b86c3b7498d4c8dc13424b42bbf95fb353b3cea | {
"func_code_index": [
4292,
4523
]
} | 1,226 |
KREEP | KREEP.sol | 0xbd9c92490b7e9444951fe86af90b6e54ab95cb16 | Solidity | Address | library Address {
/**
* @dev Returns true if `account` is a contract.
*
* [IMPORTANT]
* ====
* It is unsafe to assume that an address for which this function returns
* false is an externally-owned account (EOA) and not a contract.
*
* Among others, `isContract` will ... | /**
* @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.
*
* _Available since v3.1._
*/ | NatSpecMultiLine | v0.6.12+commit.27d51765 | None | ipfs://39a71624c52ee018a303c30d9b86c3b7498d4c8dc13424b42bbf95fb353b3cea | {
"func_code_index": [
4774,
5095
]
} | 1,227 |
KREEP | KREEP.sol | 0xbd9c92490b7e9444951fe86af90b6e54ab95cb16 | Solidity | Ownable | contract Ownable is Context {
address private _owner;
address private _previousOwner;
uint256 private _lockTime;
event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);
/**
* @dev Initializes the contract setting the deployer as the initial owner.
*/... | /**
* @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() public view returns (address) {
return _owner;
}
| /**
* @dev Returns the address of the current owner.
*/ | NatSpecMultiLine | v0.6.12+commit.27d51765 | None | ipfs://39a71624c52ee018a303c30d9b86c3b7498d4c8dc13424b42bbf95fb353b3cea | {
"func_code_index": [
566,
650
]
} | 1,228 |
KREEP | KREEP.sol | 0xbd9c92490b7e9444951fe86af90b6e54ab95cb16 | Solidity | Ownable | contract Ownable is Context {
address private _owner;
address private _previousOwner;
uint256 private _lockTime;
event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);
/**
* @dev Initializes the contract setting the deployer as the initial owner.
*/... | /**
* @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 onlyOwner {
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.
*
* NOTE: Renouncing ownership will leave the contract without an owner,
* thereby removing any functionality that is only available to the owner.
*/ | NatSpecMultiLine | v0.6.12+commit.27d51765 | None | ipfs://39a71624c52ee018a303c30d9b86c3b7498d4c8dc13424b42bbf95fb353b3cea | {
"func_code_index": [
1209,
1362
]
} | 1,229 |
KREEP | KREEP.sol | 0xbd9c92490b7e9444951fe86af90b6e54ab95cb16 | Solidity | Ownable | contract Ownable is Context {
address private _owner;
address private _previousOwner;
uint256 private _lockTime;
event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);
/**
* @dev Initializes the contract setting the deployer as the initial owner.
*/... | /**
* @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 | transferOwnership | function transferOwnership(address newOwner) public virtual onlyOwner {
require(newOwner != address(0), "Ownable: new owner is the zero address");
emit OwnershipTransferred(_owner, newOwner);
_owner = newOwner;
}
| /**
* @dev Transfers ownership of the contract to a new account (`newOwner`).
* Can only be called by the current owner.
*/ | NatSpecMultiLine | v0.6.12+commit.27d51765 | None | ipfs://39a71624c52ee018a303c30d9b86c3b7498d4c8dc13424b42bbf95fb353b3cea | {
"func_code_index": [
1512,
1761
]
} | 1,230 |
KREEP | KREEP.sol | 0xbd9c92490b7e9444951fe86af90b6e54ab95cb16 | Solidity | Ownable | contract Ownable is Context {
address private _owner;
address private _previousOwner;
uint256 private _lockTime;
event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);
/**
* @dev Initializes the contract setting the deployer as the initial owner.
*/... | /**
* @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 | lock | function lock(uint256 time) public virtual onlyOwner {
_previousOwner = _owner;
_owner = address(0);
_lockTime = now + time;
emit OwnershipTransferred(_owner, address(0));
}
| //Locks the contract for owner for the amount of time provided | LineComment | v0.6.12+commit.27d51765 | None | ipfs://39a71624c52ee018a303c30d9b86c3b7498d4c8dc13424b42bbf95fb353b3cea | {
"func_code_index": [
1929,
2148
]
} | 1,231 |
KREEP | KREEP.sol | 0xbd9c92490b7e9444951fe86af90b6e54ab95cb16 | Solidity | Ownable | contract Ownable is Context {
address private _owner;
address private _previousOwner;
uint256 private _lockTime;
event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);
/**
* @dev Initializes the contract setting the deployer as the initial owner.
*/... | /**
* @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 | unlock | function unlock() public virtual {
require(_previousOwner == msg.sender, "You don't have permission to unlock");
require(now > _lockTime , "Contract is locked until 7 days");
emit OwnershipTransferred(_owner, _previousOwner);
_owner = _previousOwner;
}
| //Unlocks the contract for owner when _lockTime is exceeds | LineComment | v0.6.12+commit.27d51765 | None | ipfs://39a71624c52ee018a303c30d9b86c3b7498d4c8dc13424b42bbf95fb353b3cea | {
"func_code_index": [
2219,
2517
]
} | 1,232 |
KREEP | KREEP.sol | 0xbd9c92490b7e9444951fe86af90b6e54ab95cb16 | Solidity | KREEP | contract KREEP is Context, IERC20, Ownable {
using SafeMath for uint256;
using Address for address;
mapping (address => uint256) private _rOwned;
mapping (address => uint256) private _tOwned;
mapping (address => mapping (address => uint256)) private _allowances;
mapping (address => boo... | //to recieve ETH from uniswapV2Router when swaping | LineComment | v0.6.12+commit.27d51765 | None | ipfs://39a71624c52ee018a303c30d9b86c3b7498d4c8dc13424b42bbf95fb353b3cea | {
"func_code_index": [
8141,
8175
]
} | 1,233 | ||||
KREEP | KREEP.sol | 0xbd9c92490b7e9444951fe86af90b6e54ab95cb16 | Solidity | KREEP | contract KREEP is Context, IERC20, Ownable {
using SafeMath for uint256;
using Address for address;
mapping (address => uint256) private _rOwned;
mapping (address => uint256) private _tOwned;
mapping (address => mapping (address => uint256)) private _allowances;
mapping (address => boo... | _tokenTransfer | function _tokenTransfer(address sender, address recipient, uint256 amount,bool takeFee) private {
if(!takeFee)
removeAllFee();
if (_isExcluded[sender] && !_isExcluded[recipient]) {
_transferFromExcluded(sender, recipient, amount);
} else if (!_isExcluded[sender] && _isExcluded... | //this method is responsible for taking all fee, if takeFee is true | LineComment | v0.6.12+commit.27d51765 | None | ipfs://39a71624c52ee018a303c30d9b86c3b7498d4c8dc13424b42bbf95fb353b3cea | {
"func_code_index": [
15866,
16705
]
} | 1,234 | ||
UniV3LiquidityAMO | contracts/Uniswap_V3/periphery/libraries/PoolAddress.sol | 0xc687e65456ff664b95753e3ee02a5e5d4fdbe886 | Solidity | PoolAddress | library PoolAddress {
bytes32 internal constant POOL_INIT_CODE_HASH = 0xe34f199b19b2b4f47f68442619d555527d244f78a3297ea89325f843f87b8b54;
/// @notice The identifying key of the pool
struct PoolKey {
address token0;
address token1;
uint24 fee;
}
/// @notice Returns PoolKey: ... | /// @title Provides functions for deriving a pool address from the factory, tokens, and the fee | NatSpecSingleLine | getPoolKey | function getPoolKey(
address tokenA,
address tokenB,
uint24 fee
) internal pure returns (PoolKey memory) {
if (tokenA > tokenB) (tokenA, tokenB) = (tokenB, tokenA);
return PoolKey({token0: tokenA, token1: tokenB, fee: fee});
}
| /// @notice Returns PoolKey: the ordered tokens with the matched fee levels
/// @param tokenA The first token of a pool, unsorted
/// @param tokenB The second token of a pool, unsorted
/// @param fee The fee level of the pool
/// @return Poolkey The pool details with ordered token0 and token1 assignments | NatSpecSingleLine | v0.8.4+commit.c7e474f2 | {
"func_code_index": [
613,
891
]
} | 1,235 | ||
UniV3LiquidityAMO | contracts/Uniswap_V3/periphery/libraries/PoolAddress.sol | 0xc687e65456ff664b95753e3ee02a5e5d4fdbe886 | Solidity | PoolAddress | library PoolAddress {
bytes32 internal constant POOL_INIT_CODE_HASH = 0xe34f199b19b2b4f47f68442619d555527d244f78a3297ea89325f843f87b8b54;
/// @notice The identifying key of the pool
struct PoolKey {
address token0;
address token1;
uint24 fee;
}
/// @notice Returns PoolKey: ... | /// @title Provides functions for deriving a pool address from the factory, tokens, and the fee | NatSpecSingleLine | computeAddress | function computeAddress(address factory, PoolKey memory key) internal pure returns (address pool) {
require(key.token0 < key.token1);
pool = address(uint160(
uint256(
keccak256(
abi.encodePacked(
hex'ff',
factory,
ke... | /// @notice Deterministically computes the pool address given the factory and PoolKey
/// @param factory The Uniswap V3 factory contract address
/// @param key The PoolKey
/// @return pool The contract address of the V3 pool | NatSpecSingleLine | v0.8.4+commit.c7e474f2 | {
"func_code_index": [
1134,
1659
]
} | 1,236 | ||
BRMP | BRMP.sol | 0xea3b77d0322b427453300df08f23ee6c071aaebc | Solidity | BRMP | contract BRMP is Owned, ERC20Token {
using SafeMath for uint256;
string private constant standard = "201907043306";
string private constant version = "6.0663688";
string private name_ = "Borrme Points";
string private symbol_ = "BRMP";
uint8 private decimals_ = 18;
uint256 private t... | // the main ERC20-compliant multi-timelock enabled contract | LineComment | setUnlockEarlier | function setUnlockEarlier(uint256 _earlier) public onlyOwner {
earlier = earlier.add(_earlier);
}
| // fast-forward the timelocks for all accounts | LineComment | v0.4.26+commit.4563c3fc | bzzr://0db19956575b13220b4f08b353bc03ba65f05ac41f0203c4a9f88831c40d3012 | {
"func_code_index": [
1727,
1843
]
} | 1,237 | |
BRMP | BRMP.sol | 0xea3b77d0322b427453300df08f23ee6c071aaebc | Solidity | BRMP | contract BRMP is Owned, ERC20Token {
using SafeMath for uint256;
string private constant standard = "201907043306";
string private constant version = "6.0663688";
string private name_ = "Borrme Points";
string private symbol_ = "BRMP";
uint8 private decimals_ = 18;
uint256 private t... | // the main ERC20-compliant multi-timelock enabled contract | LineComment | setUnlockLater | function setUnlockLater(uint256 _later) public onlyOwner {
later = later.add(_later);
}
| // delay the timelocks for all accounts | LineComment | v0.4.26+commit.4563c3fc | bzzr://0db19956575b13220b4f08b353bc03ba65f05ac41f0203c4a9f88831c40d3012 | {
"func_code_index": [
1891,
1997
]
} | 1,238 | |
BRMP | BRMP.sol | 0xea3b77d0322b427453300df08f23ee6c071aaebc | Solidity | BRMP | contract BRMP is Owned, ERC20Token {
using SafeMath for uint256;
string private constant standard = "201907043306";
string private constant version = "6.0663688";
string private name_ = "Borrme Points";
string private symbol_ = "BRMP";
uint8 private decimals_ = 18;
uint256 private t... | // the main ERC20-compliant multi-timelock enabled contract | LineComment | disableMint | function disableMint() public onlyOwner isMintable {
mintable_ = false;
}
| // owner may permanently disable minting | LineComment | v0.4.26+commit.4563c3fc | bzzr://0db19956575b13220b4f08b353bc03ba65f05ac41f0203c4a9f88831c40d3012 | {
"func_code_index": [
2046,
2138
]
} | 1,239 | |
BRMP | BRMP.sol | 0xea3b77d0322b427453300df08f23ee6c071aaebc | Solidity | BRMP | contract BRMP is Owned, ERC20Token {
using SafeMath for uint256;
string private constant standard = "201907043306";
string private constant version = "6.0663688";
string private name_ = "Borrme Points";
string private symbol_ = "BRMP";
uint8 private decimals_ = 18;
uint256 private t... | // the main ERC20-compliant multi-timelock enabled contract | LineComment | mintable | function mintable() public view returns (bool) {
return mintable_;
}
| // show if the token is still mintable | LineComment | v0.4.26+commit.4563c3fc | bzzr://0db19956575b13220b4f08b353bc03ba65f05ac41f0203c4a9f88831c40d3012 | {
"func_code_index": [
2185,
2272
]
} | 1,240 | |
BRMP | BRMP.sol | 0xea3b77d0322b427453300df08f23ee6c071aaebc | Solidity | BRMP | contract BRMP is Owned, ERC20Token {
using SafeMath for uint256;
string private constant standard = "201907043306";
string private constant version = "6.0663688";
string private name_ = "Borrme Points";
string private symbol_ = "BRMP";
uint8 private decimals_ = 18;
uint256 private t... | // the main ERC20-compliant multi-timelock enabled contract | LineComment | name | function name() public view returns (string) {
return name_;
}
| // standard ERC20 name function | LineComment | v0.4.26+commit.4563c3fc | bzzr://0db19956575b13220b4f08b353bc03ba65f05ac41f0203c4a9f88831c40d3012 | {
"func_code_index": [
2312,
2393
]
} | 1,241 | |
BRMP | BRMP.sol | 0xea3b77d0322b427453300df08f23ee6c071aaebc | Solidity | BRMP | contract BRMP is Owned, ERC20Token {
using SafeMath for uint256;
string private constant standard = "201907043306";
string private constant version = "6.0663688";
string private name_ = "Borrme Points";
string private symbol_ = "BRMP";
uint8 private decimals_ = 18;
uint256 private t... | // the main ERC20-compliant multi-timelock enabled contract | LineComment | symbol | function symbol() public view returns (string) {
return symbol_;
}
| // standard ERC20 symbol function | LineComment | v0.4.26+commit.4563c3fc | bzzr://0db19956575b13220b4f08b353bc03ba65f05ac41f0203c4a9f88831c40d3012 | {
"func_code_index": [
2435,
2520
]
} | 1,242 | |
BRMP | BRMP.sol | 0xea3b77d0322b427453300df08f23ee6c071aaebc | Solidity | BRMP | contract BRMP is Owned, ERC20Token {
using SafeMath for uint256;
string private constant standard = "201907043306";
string private constant version = "6.0663688";
string private name_ = "Borrme Points";
string private symbol_ = "BRMP";
uint8 private decimals_ = 18;
uint256 private t... | // the main ERC20-compliant multi-timelock enabled contract | LineComment | decimals | function decimals() public view returns (uint8) {
return decimals_;
}
| // standard ERC20 decimals function | LineComment | v0.4.26+commit.4563c3fc | bzzr://0db19956575b13220b4f08b353bc03ba65f05ac41f0203c4a9f88831c40d3012 | {
"func_code_index": [
2564,
2652
]
} | 1,243 | |
BRMP | BRMP.sol | 0xea3b77d0322b427453300df08f23ee6c071aaebc | Solidity | BRMP | contract BRMP is Owned, ERC20Token {
using SafeMath for uint256;
string private constant standard = "201907043306";
string private constant version = "6.0663688";
string private name_ = "Borrme Points";
string private symbol_ = "BRMP";
uint8 private decimals_ = 18;
uint256 private t... | // the main ERC20-compliant multi-timelock enabled contract | LineComment | totalSupply | function totalSupply() public view returns (uint256) {
return totalSupply_;
}
| // standard ERC20 totalSupply function | LineComment | v0.4.26+commit.4563c3fc | bzzr://0db19956575b13220b4f08b353bc03ba65f05ac41f0203c4a9f88831c40d3012 | {
"func_code_index": [
2699,
2795
]
} | 1,244 | |
BRMP | BRMP.sol | 0xea3b77d0322b427453300df08f23ee6c071aaebc | Solidity | BRMP | contract BRMP is Owned, ERC20Token {
using SafeMath for uint256;
string private constant standard = "201907043306";
string private constant version = "6.0663688";
string private name_ = "Borrme Points";
string private symbol_ = "BRMP";
uint8 private decimals_ = 18;
uint256 private t... | // the main ERC20-compliant multi-timelock enabled contract | LineComment | allowance | function allowance(address _owner, address _spender) external view returns (uint256) {
return allowed[_owner][_spender];
}
| // standard ERC20 allowance function | LineComment | v0.4.26+commit.4563c3fc | bzzr://0db19956575b13220b4f08b353bc03ba65f05ac41f0203c4a9f88831c40d3012 | {
"func_code_index": [
2840,
2981
]
} | 1,245 | |
BRMP | BRMP.sol | 0xea3b77d0322b427453300df08f23ee6c071aaebc | Solidity | BRMP | contract BRMP is Owned, ERC20Token {
using SafeMath for uint256;
string private constant standard = "201907043306";
string private constant version = "6.0663688";
string private name_ = "Borrme Points";
string private symbol_ = "BRMP";
uint8 private decimals_ = 18;
uint256 private t... | // the main ERC20-compliant multi-timelock enabled contract | LineComment | balanceUnlocked | function balanceUnlocked(address _address) public view returns (uint256 _balance) {
_balance = balanceP[_address];
uint256 i = 0;
while (i < lockNum[_address]) {
if (now.add(earlier) >= lockTime[_address][i].add(later)) _balance = _balance.add(lockValue[_address][i]);
i++;
}
r... | // show unlocked balance of an account | LineComment | v0.4.26+commit.4563c3fc | bzzr://0db19956575b13220b4f08b353bc03ba65f05ac41f0203c4a9f88831c40d3012 | {
"func_code_index": [
3028,
3403
]
} | 1,246 | |
BRMP | BRMP.sol | 0xea3b77d0322b427453300df08f23ee6c071aaebc | Solidity | BRMP | contract BRMP is Owned, ERC20Token {
using SafeMath for uint256;
string private constant standard = "201907043306";
string private constant version = "6.0663688";
string private name_ = "Borrme Points";
string private symbol_ = "BRMP";
uint8 private decimals_ = 18;
uint256 private t... | // the main ERC20-compliant multi-timelock enabled contract | LineComment | balanceLocked | function balanceLocked(address _address) public view returns (uint256 _balance) {
_balance = 0;
uint256 i = 0;
while (i < lockNum[_address]) {
if (now.add(earlier) < lockTime[_address][i].add(later)) _balance = _balance.add(lockValue[_address][i]);
i++;
}
return _balance;
}
... | // show timelocked balance of an account | LineComment | v0.4.26+commit.4563c3fc | bzzr://0db19956575b13220b4f08b353bc03ba65f05ac41f0203c4a9f88831c40d3012 | {
"func_code_index": [
3452,
3808
]
} | 1,247 | |
BRMP | BRMP.sol | 0xea3b77d0322b427453300df08f23ee6c071aaebc | Solidity | BRMP | contract BRMP is Owned, ERC20Token {
using SafeMath for uint256;
string private constant standard = "201907043306";
string private constant version = "6.0663688";
string private name_ = "Borrme Points";
string private symbol_ = "BRMP";
uint8 private decimals_ = 18;
uint256 private t... | // the main ERC20-compliant multi-timelock enabled contract | LineComment | balanceOf | function balanceOf(address _address) public view returns (uint256 _balance) {
_balance = balanceP[_address];
uint256 i = 0;
while (i < lockNum[_address]) {
_balance = _balance.add(lockValue[_address][i]);
i++;
}
return _balance;
}
| // standard ERC20 balanceOf with timelock added | LineComment | v0.4.26+commit.4563c3fc | bzzr://0db19956575b13220b4f08b353bc03ba65f05ac41f0203c4a9f88831c40d3012 | {
"func_code_index": [
3864,
4175
]
} | 1,248 | |
BRMP | BRMP.sol | 0xea3b77d0322b427453300df08f23ee6c071aaebc | Solidity | BRMP | contract BRMP is Owned, ERC20Token {
using SafeMath for uint256;
string private constant standard = "201907043306";
string private constant version = "6.0663688";
string private name_ = "Borrme Points";
string private symbol_ = "BRMP";
uint8 private decimals_ = 18;
uint256 private t... | // the main ERC20-compliant multi-timelock enabled contract | LineComment | showLockTimes | function showLockTimes(address _address) public view validAddress(_address) returns (uint256[] _times) {
uint i = 0;
uint256[] memory tempLockTime = new uint256[](lockNum[_address]);
while (i < lockNum[_address]) {
tempLockTime[i] = lockTime[_address][i].add(later).sub(earlier);
i++;
... | // show timelocks in an account | LineComment | v0.4.26+commit.4563c3fc | bzzr://0db19956575b13220b4f08b353bc03ba65f05ac41f0203c4a9f88831c40d3012 | {
"func_code_index": [
4215,
4605
]
} | 1,249 | |
BRMP | BRMP.sol | 0xea3b77d0322b427453300df08f23ee6c071aaebc | Solidity | BRMP | contract BRMP is Owned, ERC20Token {
using SafeMath for uint256;
string private constant standard = "201907043306";
string private constant version = "6.0663688";
string private name_ = "Borrme Points";
string private symbol_ = "BRMP";
uint8 private decimals_ = 18;
uint256 private t... | // the main ERC20-compliant multi-timelock enabled contract | LineComment | showLockValues | function showLockValues(address _address) public view validAddress(_address) returns (uint256[] _values) {
return lockValue[_address];
}
| // show values locked in an account's timelocks | LineComment | v0.4.26+commit.4563c3fc | bzzr://0db19956575b13220b4f08b353bc03ba65f05ac41f0203c4a9f88831c40d3012 | {
"func_code_index": [
4661,
4816
]
} | 1,250 | |
BRMP | BRMP.sol | 0xea3b77d0322b427453300df08f23ee6c071aaebc | Solidity | BRMP | contract BRMP is Owned, ERC20Token {
using SafeMath for uint256;
string private constant standard = "201907043306";
string private constant version = "6.0663688";
string private name_ = "Borrme Points";
string private symbol_ = "BRMP";
uint8 private decimals_ = 18;
uint256 private t... | // the main ERC20-compliant multi-timelock enabled contract | LineComment | calcUnlock | function calcUnlock(address _address) private {
uint256 i = 0;
uint256 j = 0;
uint256[] memory currentLockTime;
uint256[] memory currentLockValue;
uint256[] memory newLockTime = new uint256[](lockNum[_address]);
uint256[] memory newLockValue = new uint256[](lockNum[_address]);
current... | // Calculate and process the timelock states of an account | LineComment | v0.4.26+commit.4563c3fc | bzzr://0db19956575b13220b4f08b353bc03ba65f05ac41f0203c4a9f88831c40d3012 | {
"func_code_index": [
5035,
6341
]
} | 1,251 | |
BRMP | BRMP.sol | 0xea3b77d0322b427453300df08f23ee6c071aaebc | Solidity | BRMP | contract BRMP is Owned, ERC20Token {
using SafeMath for uint256;
string private constant standard = "201907043306";
string private constant version = "6.0663688";
string private name_ = "Borrme Points";
string private symbol_ = "BRMP";
uint8 private decimals_ = 18;
uint256 private t... | // the main ERC20-compliant multi-timelock enabled contract | LineComment | transfer | function transfer(address _to, uint256 _value) public validAddress(_to) returns (bool _success) {
if (lockNum[msg.sender] > 0) calcUnlock(msg.sender);
require(balanceP[msg.sender] >= _value && _value >= 0);
balanceP[msg.sender] = balanceP[msg.sender].sub(_value);
balanceP[_to] = balanceP[_to].add(_v... | // standard ERC20 transfer | LineComment | v0.4.26+commit.4563c3fc | bzzr://0db19956575b13220b4f08b353bc03ba65f05ac41f0203c4a9f88831c40d3012 | {
"func_code_index": [
6376,
6801
]
} | 1,252 | |
BRMP | BRMP.sol | 0xea3b77d0322b427453300df08f23ee6c071aaebc | Solidity | BRMP | contract BRMP is Owned, ERC20Token {
using SafeMath for uint256;
string private constant standard = "201907043306";
string private constant version = "6.0663688";
string private name_ = "Borrme Points";
string private symbol_ = "BRMP";
uint8 private decimals_ = 18;
uint256 private t... | // the main ERC20-compliant multi-timelock enabled contract | LineComment | transferLocked | function transferLocked(address _to, uint256[] _time, uint256[] _value) public validAddress(_to) returns (bool _success) {
require(_value.length == _time.length);
if (lockNum[msg.sender] > 0) calcUnlock(msg.sender);
uint256 i = 0;
uint256 totalValue = 0;
while (i < _value.length) {
t... | // transfer Token with timelocks | LineComment | v0.4.26+commit.4563c3fc | bzzr://0db19956575b13220b4f08b353bc03ba65f05ac41f0203c4a9f88831c40d3012 | {
"func_code_index": [
6842,
8158
]
} | 1,253 | |
BRMP | BRMP.sol | 0xea3b77d0322b427453300df08f23ee6c071aaebc | Solidity | BRMP | contract BRMP is Owned, ERC20Token {
using SafeMath for uint256;
string private constant standard = "201907043306";
string private constant version = "6.0663688";
string private name_ = "Borrme Points";
string private symbol_ = "BRMP";
uint8 private decimals_ = 18;
uint256 private t... | // the main ERC20-compliant multi-timelock enabled contract | LineComment | transferLockedFrom | function transferLockedFrom(address _from, address _to, uint256[] _time, uint256[] _value) public
validAddress(_from) validAddress(_to) returns (bool success) {
require(_value.length == _time.length);
if (lockNum[_from] > 0) calcUnlock(_from);
uint256 i = 0;
uint256 totalValue = 0;
while (i... | // TransferFrom Token with timelocks | LineComment | v0.4.26+commit.4563c3fc | bzzr://0db19956575b13220b4f08b353bc03ba65f05ac41f0203c4a9f88831c40d3012 | {
"func_code_index": [
8203,
9661
]
} | 1,254 | |
BRMP | BRMP.sol | 0xea3b77d0322b427453300df08f23ee6c071aaebc | Solidity | BRMP | contract BRMP is Owned, ERC20Token {
using SafeMath for uint256;
string private constant standard = "201907043306";
string private constant version = "6.0663688";
string private name_ = "Borrme Points";
string private symbol_ = "BRMP";
uint8 private decimals_ = 18;
uint256 private t... | // the main ERC20-compliant multi-timelock enabled contract | LineComment | transferFrom | function transferFrom(address _from, address _to, uint256 _value) public validAddress(_from) validAddress(_to) returns (bool _success) {
if (lockNum[_from] > 0) calcUnlock(_from);
require(balanceP[_from] >= _value && _value >= 0 && allowed[_from][msg.sender] >= _value);
allowed[_from][msg.sender] = allow... | // standard ERC20 transferFrom | LineComment | v0.4.26+commit.4563c3fc | bzzr://0db19956575b13220b4f08b353bc03ba65f05ac41f0203c4a9f88831c40d3012 | {
"func_code_index": [
9700,
10252
]
} | 1,255 | |
BRMP | BRMP.sol | 0xea3b77d0322b427453300df08f23ee6c071aaebc | Solidity | BRMP | contract BRMP is Owned, ERC20Token {
using SafeMath for uint256;
string private constant standard = "201907043306";
string private constant version = "6.0663688";
string private name_ = "Borrme Points";
string private symbol_ = "BRMP";
uint8 private decimals_ = 18;
uint256 private t... | // the main ERC20-compliant multi-timelock enabled contract | LineComment | approve | function approve(address _spender, uint256 _value) public validAddress(_spender) returns (bool _success) {
if (lockNum[msg.sender] > 0) calcUnlock(msg.sender);
allowed[msg.sender][_spender] = _value;
emit Approval(msg.sender, _spender, _value);
return true;
}
| // should only be called when first setting an allowed | LineComment | v0.4.26+commit.4563c3fc | bzzr://0db19956575b13220b4f08b353bc03ba65f05ac41f0203c4a9f88831c40d3012 | {
"func_code_index": [
10315,
10620
]
} | 1,256 | |
BRMP | BRMP.sol | 0xea3b77d0322b427453300df08f23ee6c071aaebc | Solidity | BRMP | contract BRMP is Owned, ERC20Token {
using SafeMath for uint256;
string private constant standard = "201907043306";
string private constant version = "6.0663688";
string private name_ = "Borrme Points";
string private symbol_ = "BRMP";
uint8 private decimals_ = 18;
uint256 private t... | // the main ERC20-compliant multi-timelock enabled contract | LineComment | increaseApproval | function increaseApproval(address _spender, uint _value) public validAddress(_spender) returns (bool _success) {
allowed[msg.sender][_spender] = allowed[msg.sender][_spender].add(_value);
emit Approval(msg.sender, _spender, allowed[msg.sender][_spender]);
return true;
}
| // increase or decrease allowed | LineComment | v0.4.26+commit.4563c3fc | bzzr://0db19956575b13220b4f08b353bc03ba65f05ac41f0203c4a9f88831c40d3012 | {
"func_code_index": [
10660,
10967
]
} | 1,257 | |
BRMP | BRMP.sol | 0xea3b77d0322b427453300df08f23ee6c071aaebc | Solidity | BRMP | contract BRMP is Owned, ERC20Token {
using SafeMath for uint256;
string private constant standard = "201907043306";
string private constant version = "6.0663688";
string private name_ = "Borrme Points";
string private symbol_ = "BRMP";
uint8 private decimals_ = 18;
uint256 private t... | // the main ERC20-compliant multi-timelock enabled contract | LineComment | burn | function burn(uint256 _value) public onlyOwner returns (bool _success) {
if (lockNum[msg.sender] > 0) calcUnlock(msg.sender);
require(balanceP[msg.sender] >= _value && _value >= 0);
balanceP[msg.sender] = balanceP[msg.sender].sub(_value);
totalSupply_ = totalSupply_.sub(_value);
emit Burn(msg.s... | // owner may burn own token | LineComment | v0.4.26+commit.4563c3fc | bzzr://0db19956575b13220b4f08b353bc03ba65f05ac41f0203c4a9f88831c40d3012 | {
"func_code_index": [
11449,
11838
]
} | 1,258 | |
BRMP | BRMP.sol | 0xea3b77d0322b427453300df08f23ee6c071aaebc | Solidity | BRMP | contract BRMP is Owned, ERC20Token {
using SafeMath for uint256;
string private constant standard = "201907043306";
string private constant version = "6.0663688";
string private name_ = "Borrme Points";
string private symbol_ = "BRMP";
uint8 private decimals_ = 18;
uint256 private t... | // the main ERC20-compliant multi-timelock enabled contract | LineComment | mint | function mint(uint256 _value) public onlyOwner isMintable returns (bool _success) {
balanceP[msg.sender] = balanceP[msg.sender].add(_value);
totalSupply_ = totalSupply_.add(_value);
emit Mint(msg.sender, _value);
return true;
}
| // owner may mint new token and increase total supply | LineComment | v0.4.26+commit.4563c3fc | bzzr://0db19956575b13220b4f08b353bc03ba65f05ac41f0203c4a9f88831c40d3012 | {
"func_code_index": [
11900,
12173
]
} | 1,259 | |
BRMP | BRMP.sol | 0xea3b77d0322b427453300df08f23ee6c071aaebc | Solidity | BRMP | contract BRMP is Owned, ERC20Token {
using SafeMath for uint256;
string private constant standard = "201907043306";
string private constant version = "6.0663688";
string private name_ = "Borrme Points";
string private symbol_ = "BRMP";
uint8 private decimals_ = 18;
uint256 private t... | // the main ERC20-compliant multi-timelock enabled contract | LineComment | function () public payable {
revert();
}
| // safety methods | LineComment | v0.4.26+commit.4563c3fc | bzzr://0db19956575b13220b4f08b353bc03ba65f05ac41f0203c4a9f88831c40d3012 | {
"func_code_index": [
12199,
12258
]
} | 1,260 | ||
BRMP | BRMP.sol | 0xea3b77d0322b427453300df08f23ee6c071aaebc | Solidity | BRMP | contract BRMP is Owned, ERC20Token {
using SafeMath for uint256;
string private constant standard = "201907043306";
string private constant version = "6.0663688";
string private name_ = "Borrme Points";
string private symbol_ = "BRMP";
uint8 private decimals_ = 18;
uint256 private t... | // the main ERC20-compliant multi-timelock enabled contract | LineComment | emptyWrongEther | function emptyWrongEther() onlyOwner public {
uint256 amount = address(this).balance;
require(amount > 0);
msg.sender.transfer(amount);
emit WrongEtherEmptied(msg.sender, amount);
}
| // shouldn't happen, just in case | LineComment | v0.4.26+commit.4563c3fc | bzzr://0db19956575b13220b4f08b353bc03ba65f05ac41f0203c4a9f88831c40d3012 | {
"func_code_index": [
12639,
12868
]
} | 1,261 | |
MetaJoseon | contracts/Gravel.sol | 0x6350358a3671e54358404d87f3edd73155ec8473 | Solidity | MetaJoseon | contract MetaJoseon is ERC721Enumerable, Ownable {
using Strings for uint256;
string public baseURI;
string public baseExtension = ".json";
uint256 public saleState = 1;
string public notRevealedUri;
uint256 public ogMaxSupply = 250;
uint256 public wlMaxSupply = 3250;
uint256 public pMaxSupply... | _setOgwhitelistUsers | function _setOgwhitelistUsers(address[] memory _users) private onlyOwner {
delete ogWhitelistedAddresses;
ogWhitelistedAddresses = _users;
}
| // internal | LineComment | v0.8.7+commit.e28d00a7 | GNU GPLv3 | ipfs://f85091aa61000a5162ee30fc3b2a80064bdc3a0052ea298af5d6775accad2533 | {
"func_code_index": [
1225,
1381
]
} | 1,262 | ||
MetaJoseon | contracts/Gravel.sol | 0x6350358a3671e54358404d87f3edd73155ec8473 | Solidity | MetaJoseon | contract MetaJoseon is ERC721Enumerable, Ownable {
using Strings for uint256;
string public baseURI;
string public baseExtension = ".json";
uint256 public saleState = 1;
string public notRevealedUri;
uint256 public ogMaxSupply = 250;
uint256 public wlMaxSupply = 3250;
uint256 public pMaxSupply... | mint | function mint(uint256 _mintAmount) public payable {
uint256 supply = totalSupply();
uint256 ownerMintedCount = addressMintedBalance[msg.sender];
require(_mintAmount > 0, "need to mint at least 1 NFT");
if(msg.sender != owner()){
//Stop
require(saleState != 0, "the contract is paused");
... | // public | LineComment | v0.8.7+commit.e28d00a7 | GNU GPLv3 | ipfs://f85091aa61000a5162ee30fc3b2a80064bdc3a0052ea298af5d6775accad2533 | {
"func_code_index": [
1667,
3861
]
} | 1,263 | ||
MetaJoseon | contracts/Gravel.sol | 0x6350358a3671e54358404d87f3edd73155ec8473 | Solidity | MetaJoseon | contract MetaJoseon is ERC721Enumerable, Ownable {
using Strings for uint256;
string public baseURI;
string public baseExtension = ".json";
uint256 public saleState = 1;
string public notRevealedUri;
uint256 public ogMaxSupply = 250;
uint256 public wlMaxSupply = 3250;
uint256 public pMaxSupply... | reveal | function reveal() public onlyOwner {
revealed = true;
}
| //only owner | LineComment | v0.8.7+commit.e28d00a7 | GNU GPLv3 | ipfs://f85091aa61000a5162ee30fc3b2a80064bdc3a0052ea298af5d6775accad2533 | {
"func_code_index": [
5241,
5309
]
} | 1,264 | ||
MEDIKOIN | MEDIKOIN.sol | 0xe7aa03ec676f531167454b1104001b7e8c9f41b5 | Solidity | Context | contract Context {
// Empty internal constructor, to prevent people from mistakenly deploying
// an instance of this contract, which should be used via inheritance.
constructor () internal { }
// solhint-disable-previous-line no-empty-blocks
function _msgSender() internal view returns (addres... | _msgSender | function _msgSender() internal view returns (address payable) {
return msg.sender;
}
| // solhint-disable-previous-line no-empty-blocks | LineComment | v0.5.0+commit.1d4f565a | MIT | bzzr://9b0e9ada8cd87e561ce9b3b8c72cc270faf6229f66ed9efcb4b514977d1a3002 | {
"func_code_index": [
265,
368
]
} | 1,265 | ||
MEDIKOIN | MEDIKOIN.sol | 0xe7aa03ec676f531167454b1104001b7e8c9f41b5 | Solidity | IERC20 | interface IERC20 {
/**
* @dev Returns the amount of tokens in existence.
*/
function totalSupply() external view returns (uint256);
/**
* @dev Returns the amount of tokens owned by `account`.
*/
function balanceOf(address account) external view returns (uint256);
/**... | totalSupply | function totalSupply() external view returns (uint256);
| /**
* @dev Returns the amount of tokens in existence.
*/ | NatSpecMultiLine | v0.5.0+commit.1d4f565a | MIT | bzzr://9b0e9ada8cd87e561ce9b3b8c72cc270faf6229f66ed9efcb4b514977d1a3002 | {
"func_code_index": [
94,
154
]
} | 1,266 | ||
MEDIKOIN | MEDIKOIN.sol | 0xe7aa03ec676f531167454b1104001b7e8c9f41b5 | Solidity | IERC20 | interface IERC20 {
/**
* @dev Returns the amount of tokens in existence.
*/
function totalSupply() external view returns (uint256);
/**
* @dev Returns the amount of tokens owned by `account`.
*/
function balanceOf(address account) external view returns (uint256);
/**... | balanceOf | function balanceOf(address account) external view returns (uint256);
| /**
* @dev Returns the amount of tokens owned by `account`.
*/ | NatSpecMultiLine | v0.5.0+commit.1d4f565a | MIT | bzzr://9b0e9ada8cd87e561ce9b3b8c72cc270faf6229f66ed9efcb4b514977d1a3002 | {
"func_code_index": [
237,
310
]
} | 1,267 | ||
MEDIKOIN | MEDIKOIN.sol | 0xe7aa03ec676f531167454b1104001b7e8c9f41b5 | Solidity | IERC20 | interface IERC20 {
/**
* @dev Returns the amount of tokens in existence.
*/
function totalSupply() external view returns (uint256);
/**
* @dev Returns the amount of tokens owned by `account`.
*/
function balanceOf(address account) external view returns (uint256);
/**... | transfer | function transfer(address recipient, uint256 amount) external returns (bool);
| /**
* @dev Moves `amount` tokens from the caller's account to `recipient`.
*
* Returns a boolean value indicating whether the operation succeeded.
*
* Emits a {Transfer} event.
*/ | NatSpecMultiLine | v0.5.0+commit.1d4f565a | MIT | bzzr://9b0e9ada8cd87e561ce9b3b8c72cc270faf6229f66ed9efcb4b514977d1a3002 | {
"func_code_index": [
534,
616
]
} | 1,268 | ||
MEDIKOIN | MEDIKOIN.sol | 0xe7aa03ec676f531167454b1104001b7e8c9f41b5 | Solidity | IERC20 | interface IERC20 {
/**
* @dev Returns the amount of tokens in existence.
*/
function totalSupply() external view returns (uint256);
/**
* @dev Returns the amount of tokens owned by `account`.
*/
function balanceOf(address account) external view returns (uint256);
/**... | 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.5.0+commit.1d4f565a | MIT | bzzr://9b0e9ada8cd87e561ce9b3b8c72cc270faf6229f66ed9efcb4b514977d1a3002 | {
"func_code_index": [
895,
983
]
} | 1,269 | ||
MEDIKOIN | MEDIKOIN.sol | 0xe7aa03ec676f531167454b1104001b7e8c9f41b5 | Solidity | IERC20 | interface IERC20 {
/**
* @dev Returns the amount of tokens in existence.
*/
function totalSupply() external view returns (uint256);
/**
* @dev Returns the amount of tokens owned by `account`.
*/
function balanceOf(address account) external view returns (uint256);
/**... | 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.
*
* IMPORTANT: Beware that changing an allowance with this method brings the risk
* that someone may use both the old and the new allowance by unfortunate
... | NatSpecMultiLine | v0.5.0+commit.1d4f565a | MIT | bzzr://9b0e9ada8cd87e561ce9b3b8c72cc270faf6229f66ed9efcb4b514977d1a3002 | {
"func_code_index": [
1647,
1726
]
} | 1,270 | ||
MEDIKOIN | MEDIKOIN.sol | 0xe7aa03ec676f531167454b1104001b7e8c9f41b5 | Solidity | IERC20 | interface IERC20 {
/**
* @dev Returns the amount of tokens in existence.
*/
function totalSupply() external view returns (uint256);
/**
* @dev Returns the amount of tokens owned by `account`.
*/
function balanceOf(address account) external view returns (uint256);
/**... | 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.
*
* Returns a boolean value indicating whether the operation succeeded.
*
* Emits a {Transfer} event.
*/ | NatSpecMultiLine | v0.5.0+commit.1d4f565a | MIT | bzzr://9b0e9ada8cd87e561ce9b3b8c72cc270faf6229f66ed9efcb4b514977d1a3002 | {
"func_code_index": [
2039,
2141
]
} | 1,271 | ||
MEDIKOIN | MEDIKOIN.sol | 0xe7aa03ec676f531167454b1104001b7e8c9f41b5 | Solidity | SafeMath | library SafeMath {
/**
* @dev Returns the addition of two unsigned integers, reverting on
* overflow.
*
* Counterpart to Solidity's `+` operator.
*
* Requirements:
* - Addition cannot overflow.
*/
function add(uint256 a, uint256 b) internal pure returns (uint256... | 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.
*
* Requirements:
* - Addition cannot overflow.
*/ | NatSpecMultiLine | v0.5.0+commit.1d4f565a | MIT | bzzr://9b0e9ada8cd87e561ce9b3b8c72cc270faf6229f66ed9efcb4b514977d1a3002 | {
"func_code_index": [
251,
437
]
} | 1,272 | ||
MEDIKOIN | MEDIKOIN.sol | 0xe7aa03ec676f531167454b1104001b7e8c9f41b5 | Solidity | SafeMath | library SafeMath {
/**
* @dev Returns the addition of two unsigned integers, reverting on
* overflow.
*
* Counterpart to Solidity's `+` operator.
*
* Requirements:
* - Addition cannot overflow.
*/
function add(uint256 a, uint256 b) internal pure returns (uint256... | 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.
*
* Requirements:
* - Subtraction cannot overflow.
*/ | NatSpecMultiLine | v0.5.0+commit.1d4f565a | MIT | bzzr://9b0e9ada8cd87e561ce9b3b8c72cc270faf6229f66ed9efcb4b514977d1a3002 | {
"func_code_index": [
707,
848
]
} | 1,273 | ||
MEDIKOIN | MEDIKOIN.sol | 0xe7aa03ec676f531167454b1104001b7e8c9f41b5 | Solidity | SafeMath | library SafeMath {
/**
* @dev Returns the addition of two unsigned integers, reverting on
* overflow.
*
* Counterpart to Solidity's `+` operator.
*
* Requirements:
* - Addition cannot overflow.
*/
function add(uint256 a, uint256 b) internal pure returns (uint256... | 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.
*
* Requirements:
* - Subtraction cannot overflow.
*
* _Available since v2.4.0._
*/ | NatSpecMultiLine | v0.5.0+commit.1d4f565a | MIT | bzzr://9b0e9ada8cd87e561ce9b3b8c72cc270faf6229f66ed9efcb4b514977d1a3002 | {
"func_code_index": [
1180,
1377
]
} | 1,274 | ||
MEDIKOIN | MEDIKOIN.sol | 0xe7aa03ec676f531167454b1104001b7e8c9f41b5 | Solidity | SafeMath | library SafeMath {
/**
* @dev Returns the addition of two unsigned integers, reverting on
* overflow.
*
* Counterpart to Solidity's `+` operator.
*
* Requirements:
* - Addition cannot overflow.
*/
function add(uint256 a, uint256 b) internal pure returns (uint256... | 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.
*
* Requirements:
* - Multiplication cannot overflow.
*/ | NatSpecMultiLine | v0.5.0+commit.1d4f565a | MIT | bzzr://9b0e9ada8cd87e561ce9b3b8c72cc270faf6229f66ed9efcb4b514977d1a3002 | {
"func_code_index": [
1623,
2099
]
} | 1,275 | ||
MEDIKOIN | MEDIKOIN.sol | 0xe7aa03ec676f531167454b1104001b7e8c9f41b5 | Solidity | SafeMath | library SafeMath {
/**
* @dev Returns the addition of two unsigned integers, reverting on
* overflow.
*
* Counterpart to Solidity's `+` operator.
*
* Requirements:
* - Addition cannot overflow.
*/
function add(uint256 a, uint256 b) internal pure returns (uint256... | 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.5.0+commit.1d4f565a | MIT | bzzr://9b0e9ada8cd87e561ce9b3b8c72cc270faf6229f66ed9efcb4b514977d1a3002 | {
"func_code_index": [
2562,
2699
]
} | 1,276 | ||
MEDIKOIN | MEDIKOIN.sol | 0xe7aa03ec676f531167454b1104001b7e8c9f41b5 | Solidity | SafeMath | library SafeMath {
/**
* @dev Returns the addition of two unsigned integers, reverting on
* overflow.
*
* Counterpart to Solidity's `+` operator.
*
* Requirements:
* - Addition cannot overflow.
*/
function add(uint256 a, uint256 b) internal pure returns (uint256... | div | function div(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) {
// Solidity only automatically asserts when dividing by 0
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.5.0+commit.1d4f565a | MIT | bzzr://9b0e9ada8cd87e561ce9b3b8c72cc270faf6229f66ed9efcb4b514977d1a3002 | {
"func_code_index": [
3224,
3574
]
} | 1,277 | ||
MEDIKOIN | MEDIKOIN.sol | 0xe7aa03ec676f531167454b1104001b7e8c9f41b5 | Solidity | SafeMath | library SafeMath {
/**
* @dev Returns the addition of two unsigned integers, reverting on
* overflow.
*
* Counterpart to Solidity's `+` operator.
*
* Requirements:
* - Addition cannot overflow.
*/
function add(uint256 a, uint256 b) internal pure returns (uint256... | 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.5.0+commit.1d4f565a | MIT | bzzr://9b0e9ada8cd87e561ce9b3b8c72cc270faf6229f66ed9efcb4b514977d1a3002 | {
"func_code_index": [
4026,
4161
]
} | 1,278 | ||
MEDIKOIN | MEDIKOIN.sol | 0xe7aa03ec676f531167454b1104001b7e8c9f41b5 | Solidity | SafeMath | library SafeMath {
/**
* @dev Returns the addition of two unsigned integers, reverting on
* overflow.
*
* Counterpart to Solidity's `+` operator.
*
* Requirements:
* - Addition cannot overflow.
*/
function add(uint256 a, uint256 b) internal pure returns (uint256... | 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.5.0+commit.1d4f565a | MIT | bzzr://9b0e9ada8cd87e561ce9b3b8c72cc270faf6229f66ed9efcb4b514977d1a3002 | {
"func_code_index": [
4675,
4846
]
} | 1,279 | ||
MEDIKOIN | MEDIKOIN.sol | 0xe7aa03ec676f531167454b1104001b7e8c9f41b5 | Solidity | ERC20 | contract ERC20 is Context, IERC20 {
using SafeMath for uint256;
mapping (address => uint256) private _balances;
mapping (address => mapping (address => uint256)) private _allowances;
uint256 private _totalSupply;
/**
* @dev See {IERC20-totalSupply}.
*/
function totalSup... | totalSupply | function totalSupply() public view returns (uint256) {
return _totalSupply;
}
| /**
* @dev See {IERC20-totalSupply}.
*/ | NatSpecMultiLine | v0.5.0+commit.1d4f565a | MIT | bzzr://9b0e9ada8cd87e561ce9b3b8c72cc270faf6229f66ed9efcb4b514977d1a3002 | {
"func_code_index": [
299,
395
]
} | 1,280 | ||
MEDIKOIN | MEDIKOIN.sol | 0xe7aa03ec676f531167454b1104001b7e8c9f41b5 | Solidity | ERC20 | contract ERC20 is Context, IERC20 {
using SafeMath for uint256;
mapping (address => uint256) private _balances;
mapping (address => mapping (address => uint256)) private _allowances;
uint256 private _totalSupply;
/**
* @dev See {IERC20-totalSupply}.
*/
function totalSup... | balanceOf | function balanceOf(address account) public view returns (uint256) {
return _balances[account];
}
| /**
* @dev See {IERC20-balanceOf}.
*/ | NatSpecMultiLine | v0.5.0+commit.1d4f565a | MIT | bzzr://9b0e9ada8cd87e561ce9b3b8c72cc270faf6229f66ed9efcb4b514977d1a3002 | {
"func_code_index": [
453,
568
]
} | 1,281 | ||
MEDIKOIN | MEDIKOIN.sol | 0xe7aa03ec676f531167454b1104001b7e8c9f41b5 | Solidity | ERC20 | contract ERC20 is Context, IERC20 {
using SafeMath for uint256;
mapping (address => uint256) private _balances;
mapping (address => mapping (address => uint256)) private _allowances;
uint256 private _totalSupply;
/**
* @dev See {IERC20-totalSupply}.
*/
function totalSup... | transfer | function transfer(address recipient, uint256 amount) public returns (bool) {
_transfer(_msgSender(), recipient, amount);
return true;
}
| /**
* @dev See {IERC20-transfer}.
*
* Requirements:
*
* - `recipient` cannot be the zero address.
* - the caller must have a balance of at least `amount`.
*/ | NatSpecMultiLine | v0.5.0+commit.1d4f565a | MIT | bzzr://9b0e9ada8cd87e561ce9b3b8c72cc270faf6229f66ed9efcb4b514977d1a3002 | {
"func_code_index": [
776,
939
]
} | 1,282 | ||
MEDIKOIN | MEDIKOIN.sol | 0xe7aa03ec676f531167454b1104001b7e8c9f41b5 | Solidity | ERC20 | contract ERC20 is Context, IERC20 {
using SafeMath for uint256;
mapping (address => uint256) private _balances;
mapping (address => mapping (address => uint256)) private _allowances;
uint256 private _totalSupply;
/**
* @dev See {IERC20-totalSupply}.
*/
function totalSup... | allowance | function allowance(address owner, address spender) public view returns (uint256) {
return _allowances[owner][spender];
}
| /**
* @dev See {IERC20-allowance}.
*/ | NatSpecMultiLine | v0.5.0+commit.1d4f565a | MIT | bzzr://9b0e9ada8cd87e561ce9b3b8c72cc270faf6229f66ed9efcb4b514977d1a3002 | {
"func_code_index": [
997,
1136
]
} | 1,283 | ||
MEDIKOIN | MEDIKOIN.sol | 0xe7aa03ec676f531167454b1104001b7e8c9f41b5 | Solidity | ERC20 | contract ERC20 is Context, IERC20 {
using SafeMath for uint256;
mapping (address => uint256) private _balances;
mapping (address => mapping (address => uint256)) private _allowances;
uint256 private _totalSupply;
/**
* @dev See {IERC20-totalSupply}.
*/
function totalSup... | approve | function approve(address spender, uint256 amount) public returns (bool) {
_approve(_msgSender(), spender, amount);
return true;
}
| /**
* @dev See {IERC20-approve}.
*
* Requirements:
*
* - `spender` cannot be the zero address.
*/ | NatSpecMultiLine | v0.5.0+commit.1d4f565a | MIT | bzzr://9b0e9ada8cd87e561ce9b3b8c72cc270faf6229f66ed9efcb4b514977d1a3002 | {
"func_code_index": [
1278,
1435
]
} | 1,284 | ||
MEDIKOIN | MEDIKOIN.sol | 0xe7aa03ec676f531167454b1104001b7e8c9f41b5 | Solidity | ERC20 | contract ERC20 is Context, IERC20 {
using SafeMath for uint256;
mapping (address => uint256) private _balances;
mapping (address => mapping (address => uint256)) private _allowances;
uint256 private _totalSupply;
/**
* @dev See {IERC20-totalSupply}.
*/
function totalSup... | transferFrom | function transferFrom(address sender, address recipient, uint256 amount) public 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};
*
* Requirements:
* - `sender` and `recipient` cannot be the zero address.
* - `sender` must have a balance of at least `amou... | NatSpecMultiLine | v0.5.0+commit.1d4f565a | MIT | bzzr://9b0e9ada8cd87e561ce9b3b8c72cc270faf6229f66ed9efcb4b514977d1a3002 | {
"func_code_index": [
1902,
2211
]
} | 1,285 | ||
MEDIKOIN | MEDIKOIN.sol | 0xe7aa03ec676f531167454b1104001b7e8c9f41b5 | Solidity | ERC20 | contract ERC20 is Context, IERC20 {
using SafeMath for uint256;
mapping (address => uint256) private _balances;
mapping (address => mapping (address => uint256)) private _allowances;
uint256 private _totalSupply;
/**
* @dev See {IERC20-totalSupply}.
*/
function totalSup... | increaseAllowance | function increaseAllowance(address spender, uint256 addedValue) public returns (bool) {
_approve(_msgSender(), spender, _allowances[_msgSender()][spender].add(addedValue));
return true;
}
| /**
* @dev Atomically increases 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.
*
* Requirements:
*
* - `spender` c... | NatSpecMultiLine | v0.5.0+commit.1d4f565a | MIT | bzzr://9b0e9ada8cd87e561ce9b3b8c72cc270faf6229f66ed9efcb4b514977d1a3002 | {
"func_code_index": [
2615,
2830
]
} | 1,286 | ||
MEDIKOIN | MEDIKOIN.sol | 0xe7aa03ec676f531167454b1104001b7e8c9f41b5 | Solidity | ERC20 | contract ERC20 is Context, IERC20 {
using SafeMath for uint256;
mapping (address => uint256) private _balances;
mapping (address => mapping (address => uint256)) private _allowances;
uint256 private _totalSupply;
/**
* @dev See {IERC20-totalSupply}.
*/
function totalSup... | decreaseAllowance | function decreaseAllowance(address spender, uint256 subtractedValue) public 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.
*
* Requirements:
*
* - `spender` c... | NatSpecMultiLine | v0.5.0+commit.1d4f565a | MIT | bzzr://9b0e9ada8cd87e561ce9b3b8c72cc270faf6229f66ed9efcb4b514977d1a3002 | {
"func_code_index": [
3328,
3594
]
} | 1,287 | ||
MEDIKOIN | MEDIKOIN.sol | 0xe7aa03ec676f531167454b1104001b7e8c9f41b5 | Solidity | ERC20 | contract ERC20 is Context, IERC20 {
using SafeMath for uint256;
mapping (address => uint256) private _balances;
mapping (address => mapping (address => uint256)) private _allowances;
uint256 private _totalSupply;
/**
* @dev See {IERC20-totalSupply}.
*/
function totalSup... | _transfer | function _transfer(address sender, address recipient, uint256 amount) internal {
require(sender != address(0), "ERC20: transfer from the zero address");
require(recipient != address(0), "ERC20: transfer to the zero address");
_balances[sender] = _balances[sender].sub(amount, "ERC20: transfer amount exc... | /**
* @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.
*
* Requirements:
*
* - `sender` cannot be the zero address.
*... | NatSpecMultiLine | v0.5.0+commit.1d4f565a | MIT | bzzr://9b0e9ada8cd87e561ce9b3b8c72cc270faf6229f66ed9efcb4b514977d1a3002 | {
"func_code_index": [
4079,
4555
]
} | 1,288 | ||
MEDIKOIN | MEDIKOIN.sol | 0xe7aa03ec676f531167454b1104001b7e8c9f41b5 | Solidity | ERC20 | contract ERC20 is Context, IERC20 {
using SafeMath for uint256;
mapping (address => uint256) private _balances;
mapping (address => mapping (address => uint256)) private _allowances;
uint256 private _totalSupply;
/**
* @dev See {IERC20-totalSupply}.
*/
function totalSup... | _mint | function _mint(address account, uint256 amount) internal {
require(account != address(0), "ERC20: mint to the zero address");
_totalSupply = _totalSupply.add(amount);
_balances[account] = _balances[account].add(amount);
emit Transfer(address(0), account, amount);
}
| /** @dev Creates `amount` tokens and assigns them to `account`, increasing
* the total supply.
*
* Emits a {Transfer} event with `from` set to the zero address.
*
* Requirements
*
* - `to` cannot be the zero address.
*/ | NatSpecMultiLine | v0.5.0+commit.1d4f565a | MIT | bzzr://9b0e9ada8cd87e561ce9b3b8c72cc270faf6229f66ed9efcb4b514977d1a3002 | {
"func_code_index": [
4831,
5144
]
} | 1,289 | ||
MEDIKOIN | MEDIKOIN.sol | 0xe7aa03ec676f531167454b1104001b7e8c9f41b5 | Solidity | ERC20 | contract ERC20 is Context, IERC20 {
using SafeMath for uint256;
mapping (address => uint256) private _balances;
mapping (address => mapping (address => uint256)) private _allowances;
uint256 private _totalSupply;
/**
* @dev See {IERC20-totalSupply}.
*/
function totalSup... | _burn | function _burn(address account, uint256 amount) internal {
require(account != address(0), "ERC20: burn from the zero address");
_balances[account] = _balances[account].sub(amount, "ERC20: burn amount exceeds balance");
_totalSupply = _totalSupply.sub(amount);
emit Transfer(account, address(0), amo... | /**
* @dev Destroys `amount` tokens from `account`, reducing the
* total supply.
*
* Emits a {Transfer} event with `to` set to the zero address.
*
* Requirements
*
* - `account` cannot be the zero address.
* - `account` must have at least `amount` tokens.
*/ | NatSpecMultiLine | v0.5.0+commit.1d4f565a | MIT | bzzr://9b0e9ada8cd87e561ce9b3b8c72cc270faf6229f66ed9efcb4b514977d1a3002 | {
"func_code_index": [
5471,
5824
]
} | 1,290 | ||
MEDIKOIN | MEDIKOIN.sol | 0xe7aa03ec676f531167454b1104001b7e8c9f41b5 | Solidity | ERC20 | contract ERC20 is Context, IERC20 {
using SafeMath for uint256;
mapping (address => uint256) private _balances;
mapping (address => mapping (address => uint256)) private _allowances;
uint256 private _totalSupply;
/**
* @dev See {IERC20-totalSupply}.
*/
function totalSup... | _approve | function _approve(address owner, address spender, uint256 amount) internal {
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.
*
* Requirements:
*
* - `owner` cannot be the zero... | NatSpecMultiLine | v0.5.0+commit.1d4f565a | MIT | bzzr://9b0e9ada8cd87e561ce9b3b8c72cc270faf6229f66ed9efcb4b514977d1a3002 | {
"func_code_index": [
6259,
6602
]
} | 1,291 | ||
MEDIKOIN | MEDIKOIN.sol | 0xe7aa03ec676f531167454b1104001b7e8c9f41b5 | Solidity | ERC20 | contract ERC20 is Context, IERC20 {
using SafeMath for uint256;
mapping (address => uint256) private _balances;
mapping (address => mapping (address => uint256)) private _allowances;
uint256 private _totalSupply;
/**
* @dev See {IERC20-totalSupply}.
*/
function totalSup... | _burnFrom | function _burnFrom(address account, uint256 amount) internal {
_burn(account, amount);
_approve(account, _msgSender(), _allowances[account][_msgSender()].sub(amount, "ERC20: burn amount exceeds allowance"));
}
| /**
* @dev Destroys `amount` tokens from `account`.`amount` is then deducted
* from the caller's allowance.
*
* See {_burn} and {_approve}.
*/ | NatSpecMultiLine | v0.5.0+commit.1d4f565a | MIT | bzzr://9b0e9ada8cd87e561ce9b3b8c72cc270faf6229f66ed9efcb4b514977d1a3002 | {
"func_code_index": [
6783,
7020
]
} | 1,292 | ||
MEDIKOIN | MEDIKOIN.sol | 0xe7aa03ec676f531167454b1104001b7e8c9f41b5 | Solidity | Roles | library Roles {
struct Role {
mapping (address => bool) bearer;
}
/**
* @dev Give an account access to this role.
*/
function add(Role storage role, address account) internal {
require(!has(role, account), "Roles: account already has role");
role.bearer[accou... | add | function add(Role storage role, address account) internal {
require(!has(role, account), "Roles: account already has role");
role.bearer[account] = true;
}
| /**
* @dev Give an account access to this role.
*/ | NatSpecMultiLine | v0.5.0+commit.1d4f565a | MIT | bzzr://9b0e9ada8cd87e561ce9b3b8c72cc270faf6229f66ed9efcb4b514977d1a3002 | {
"func_code_index": [
156,
339
]
} | 1,293 | ||
MEDIKOIN | MEDIKOIN.sol | 0xe7aa03ec676f531167454b1104001b7e8c9f41b5 | Solidity | Roles | library Roles {
struct Role {
mapping (address => bool) bearer;
}
/**
* @dev Give an account access to this role.
*/
function add(Role storage role, address account) internal {
require(!has(role, account), "Roles: account already has role");
role.bearer[accou... | remove | function remove(Role storage role, address account) internal {
require(has(role, account), "Roles: account does not have role");
role.bearer[account] = false;
}
| /**
* @dev Remove an account's access to this role.
*/ | NatSpecMultiLine | v0.5.0+commit.1d4f565a | MIT | bzzr://9b0e9ada8cd87e561ce9b3b8c72cc270faf6229f66ed9efcb4b514977d1a3002 | {
"func_code_index": [
414,
602
]
} | 1,294 | ||
MEDIKOIN | MEDIKOIN.sol | 0xe7aa03ec676f531167454b1104001b7e8c9f41b5 | Solidity | Roles | library Roles {
struct Role {
mapping (address => bool) bearer;
}
/**
* @dev Give an account access to this role.
*/
function add(Role storage role, address account) internal {
require(!has(role, account), "Roles: account already has role");
role.bearer[accou... | has | function has(Role storage role, address account) internal view returns (bool) {
require(account != address(0), "Roles: account is the zero address");
return role.bearer[account];
}
| /**
* @dev Check if an account has this role.
* @return bool
*/ | NatSpecMultiLine | v0.5.0+commit.1d4f565a | MIT | bzzr://9b0e9ada8cd87e561ce9b3b8c72cc270faf6229f66ed9efcb4b514977d1a3002 | {
"func_code_index": [
692,
900
]
} | 1,295 | ||
MEDIKOIN | MEDIKOIN.sol | 0xe7aa03ec676f531167454b1104001b7e8c9f41b5 | Solidity | ERC20Mintable | contract ERC20Mintable is ERC20, MinterRole {
/**
* @dev See {ERC20-_mint}.
*
* Requirements:
*
* - the caller must have the {MinterRole}.
*/
function mint(address account, uint256 amount) public onlyMinter returns (bool) {
_mint(account, amount);
return t... | mint | function mint(address account, uint256 amount) public onlyMinter returns (bool) {
_mint(account, amount);
return true;
}
| /**
* @dev See {ERC20-_mint}.
*
* Requirements:
*
* - the caller must have the {MinterRole}.
*/ | NatSpecMultiLine | v0.5.0+commit.1d4f565a | MIT | bzzr://9b0e9ada8cd87e561ce9b3b8c72cc270faf6229f66ed9efcb4b514977d1a3002 | {
"func_code_index": [
184,
332
]
} | 1,296 | ||
MEDIKOIN | MEDIKOIN.sol | 0xe7aa03ec676f531167454b1104001b7e8c9f41b5 | Solidity | ERC20Capped | contract ERC20Capped is ERC20Mintable {
uint256 private _cap;
/**
* @dev Sets the value of the `cap`. This value is immutable, it can only be
* set once during construction.
*/
constructor (uint256 cap) public {
require(cap > 0, "ERC20Capped: cap is 0");
_cap = cap;
... | cap | function cap() public view returns (uint256) {
return _cap;
}
| /**
* @dev Returns the cap on the token's total supply.
*/ | NatSpecMultiLine | v0.5.0+commit.1d4f565a | MIT | bzzr://9b0e9ada8cd87e561ce9b3b8c72cc270faf6229f66ed9efcb4b514977d1a3002 | {
"func_code_index": [
406,
486
]
} | 1,297 | ||
MEDIKOIN | MEDIKOIN.sol | 0xe7aa03ec676f531167454b1104001b7e8c9f41b5 | Solidity | ERC20Capped | contract ERC20Capped is ERC20Mintable {
uint256 private _cap;
/**
* @dev Sets the value of the `cap`. This value is immutable, it can only be
* set once during construction.
*/
constructor (uint256 cap) public {
require(cap > 0, "ERC20Capped: cap is 0");
_cap = cap;
... | _mint | function _mint(address account, uint256 value) internal {
require(totalSupply().add(value) <= _cap, "ERC20Capped: cap exceeded");
super._mint(account, value);
}
| /**
* @dev See {ERC20Mintable-mint}.
*
* Requirements:
*
* - `value` must not cause the total supply to go over the cap.
*/ | NatSpecMultiLine | v0.5.0+commit.1d4f565a | MIT | bzzr://9b0e9ada8cd87e561ce9b3b8c72cc270faf6229f66ed9efcb4b514977d1a3002 | {
"func_code_index": [
654,
842
]
} | 1,298 | ||
MEDIKOIN | MEDIKOIN.sol | 0xe7aa03ec676f531167454b1104001b7e8c9f41b5 | Solidity | ERC20Detailed | contract ERC20Detailed is IERC20 {
string private _name;
string private _symbol;
uint8 private _decimals;
/**
* @dev Sets the values for `name`, `symbol`, and `decimals`. All three of
* these values are immutable: they can only be set once during
* construction.
*/
con... | name | function name() public view returns (string memory) {
return _name;
}
| /**
* @dev Returns the name of the token.
*/ | NatSpecMultiLine | v0.5.0+commit.1d4f565a | MIT | bzzr://9b0e9ada8cd87e561ce9b3b8c72cc270faf6229f66ed9efcb4b514977d1a3002 | {
"func_code_index": [
550,
638
]
} | 1,299 | ||
MEDIKOIN | MEDIKOIN.sol | 0xe7aa03ec676f531167454b1104001b7e8c9f41b5 | Solidity | ERC20Detailed | contract ERC20Detailed is IERC20 {
string private _name;
string private _symbol;
uint8 private _decimals;
/**
* @dev Sets the values for `name`, `symbol`, and `decimals`. All three of
* these values are immutable: they can only be set once during
* construction.
*/
con... | symbol | function symbol() public view returns (string memory) {
return _symbol;
}
| /**
* @dev Returns the symbol of the token, usually a shorter version of the
* name.
*/ | NatSpecMultiLine | v0.5.0+commit.1d4f565a | MIT | bzzr://9b0e9ada8cd87e561ce9b3b8c72cc270faf6229f66ed9efcb4b514977d1a3002 | {
"func_code_index": [
752,
844
]
} | 1,300 | ||
MEDIKOIN | MEDIKOIN.sol | 0xe7aa03ec676f531167454b1104001b7e8c9f41b5 | Solidity | ERC20Detailed | contract ERC20Detailed is IERC20 {
string private _name;
string private _symbol;
uint8 private _decimals;
/**
* @dev Sets the values for `name`, `symbol`, and `decimals`. All three of
* these values are immutable: they can only be set once during
* construction.
*/
con... | decimals | function decimals() public view returns (uint8) {
return _decimals;
}
| /**
* @dev Returns the number of decimals used to get its user representation.
* For example, if `decimals` equals `2`, a balance of `505` tokens should
* be displayed to a user as `5,05` (`505 / 10 ** 2`).
*
* Tokens usually opt for a value of 18, imitating the relationship between
* Ether and Wei.
*
*... | NatSpecMultiLine | v0.5.0+commit.1d4f565a | MIT | bzzr://9b0e9ada8cd87e561ce9b3b8c72cc270faf6229f66ed9efcb4b514977d1a3002 | {
"func_code_index": [
1402,
1490
]
} | 1,301 | ||
MEDIKOIN | MEDIKOIN.sol | 0xe7aa03ec676f531167454b1104001b7e8c9f41b5 | Solidity | Pausable | contract Pausable is Context, PauserRole {
/**
* @dev Emitted when the pause is triggered by a pauser (`account`).
*/
event Paused(address account);
/**
* @dev Emitted when the pause is lifted by a pauser (`account`).
*/
event Unpaused(address account);
bool private ... | paused | function paused() public view returns (bool) {
return _paused;
}
| /**
* @dev Returns true if the contract is paused, and false otherwise.
*/ | NatSpecMultiLine | v0.5.0+commit.1d4f565a | MIT | bzzr://9b0e9ada8cd87e561ce9b3b8c72cc270faf6229f66ed9efcb4b514977d1a3002 | {
"func_code_index": [
614,
697
]
} | 1,302 | ||
MEDIKOIN | MEDIKOIN.sol | 0xe7aa03ec676f531167454b1104001b7e8c9f41b5 | Solidity | Pausable | contract Pausable is Context, PauserRole {
/**
* @dev Emitted when the pause is triggered by a pauser (`account`).
*/
event Paused(address account);
/**
* @dev Emitted when the pause is lifted by a pauser (`account`).
*/
event Unpaused(address account);
bool private ... | pause | function pause() public onlyPauser whenNotPaused {
_paused = true;
emit Paused(_msgSender());
}
| /**
* @dev Called by a pauser to pause, triggers stopped state.
*/ | NatSpecMultiLine | v0.5.0+commit.1d4f565a | MIT | bzzr://9b0e9ada8cd87e561ce9b3b8c72cc270faf6229f66ed9efcb4b514977d1a3002 | {
"func_code_index": [
1194,
1317
]
} | 1,303 | ||
MEDIKOIN | MEDIKOIN.sol | 0xe7aa03ec676f531167454b1104001b7e8c9f41b5 | Solidity | Pausable | contract Pausable is Context, PauserRole {
/**
* @dev Emitted when the pause is triggered by a pauser (`account`).
*/
event Paused(address account);
/**
* @dev Emitted when the pause is lifted by a pauser (`account`).
*/
event Unpaused(address account);
bool private ... | unpause | function unpause() public onlyPauser whenPaused {
_paused = false;
emit Unpaused(_msgSender());
}
| /**
* @dev Called by a pauser to unpause, returns to normal state.
*/ | NatSpecMultiLine | v0.5.0+commit.1d4f565a | MIT | bzzr://9b0e9ada8cd87e561ce9b3b8c72cc270faf6229f66ed9efcb4b514977d1a3002 | {
"func_code_index": [
1407,
1532
]
} | 1,304 | ||
UniswapZAP | contracts/UniswapZAP.sol | 0x4c72653b2f0916ced776c6514926112f289f4484 | Solidity | UniswapZAP | contract UniswapZAP {
using SafeMath for uint256;
address public _token;
address public _tokenWETHPair;
IWETH public _WETH;
bool private initialized;
function initUniswapZAP(address token, address WETH, address tokenWethPair) public {
require(!initialized);
_token ... | // --------------------------------------------------------------------- | LineComment | addLiquidityTokensOnly | function addLiquidityTokensOnly(address from, address payable to, uint amount) public {
require(to != address(0), "Invalid address");
uint256 buyAmount = amount.div(2);
require(buyAmount > 0, "Insufficient Token amount");
(uint256 reserveWeth, uint256 reserveTokens) = getPairReserves();
uin... | /// @dev Add liquidity functions | NatSpecSingleLine | v0.6.12+commit.27d51765 | GNU GPLv3 | ipfs://5fb53e5c71bd6136fc00a0d29e9342d2965b11229f23c3eabfbda699263fb011 | {
"func_code_index": [
1663,
2524
]
} | 1,305 |
UniswapZAP | contracts/UniswapZAP.sol | 0x4c72653b2f0916ced776c6514926112f289f4484 | Solidity | UniswapZAP | contract UniswapZAP {
using SafeMath for uint256;
address public _token;
address public _tokenWETHPair;
IWETH public _WETH;
bool private initialized;
function initUniswapZAP(address token, address WETH, address tokenWethPair) public {
require(!initialized);
_token ... | // --------------------------------------------------------------------- | LineComment | safeApprove | function safeApprove(address token, address to, uint value) internal {
// bytes4(keccak256(bytes('approve(address,uint256)')));
(bool success, bytes memory data) = token.call(abi.encodeWithSelector(0x095ea7b3, to, value));
require(success && (data.length == 0 || abi.decode(data, (bool))), 'TransferHelper... | /// @dev Transfer helper from UniswapV2 Router | NatSpecSingleLine | v0.6.12+commit.27d51765 | GNU GPLv3 | ipfs://5fb53e5c71bd6136fc00a0d29e9342d2965b11229f23c3eabfbda699263fb011 | {
"func_code_index": [
8540,
8903
]
} | 1,306 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.