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
Component
Component.sol
0x4ab3d420504cfb1188ce3b805e9c3c32c2531f2e
Solidity
ABDKMath64x64
library ABDKMath64x64 { /** * Minimum value signed 64.64-bit fixed point number may have. */ int128 private constant MIN_64x64 = -0x80000000000000000000000000000000; /** * Maximum value signed 64.64-bit fixed point number may have. */ int128 private constant MAX_64x64 = 0x7FFFFFFFFFFFFFF...
/** * Smart contract library of mathematical functions operating with signed * 64.64-bit fixed point numbers. Signed 64.64-bit fixed point number is * basically a simple fraction whose numerator is signed 128-bit integer and * denominator is 2^64. As long as denominator is always the same, there is no * nee...
NatSpecMultiLine
sqrt
function sqrt (int128 x) internal pure returns (int128) { require (x >= 0); return int128 (sqrtu (uint256 (x) << 64, 0x10000000000000000)); }
/** * Calculate sqrt (x) rounding down. Revert if x < 0. * * @param x signed 64.64-bit fixed point number * @return signed 64.64-bit fixed point number */
NatSpecMultiLine
v0.5.17+commit.d19bba13
Unknown
bzzr://44f9869efe6cff5c5f543e2191ede97c1cdac7b3bccb186e17921ad8921ec0be
{ "func_code_index": [ 11253, 11410 ] }
10,200
Component
Component.sol
0x4ab3d420504cfb1188ce3b805e9c3c32c2531f2e
Solidity
ABDKMath64x64
library ABDKMath64x64 { /** * Minimum value signed 64.64-bit fixed point number may have. */ int128 private constant MIN_64x64 = -0x80000000000000000000000000000000; /** * Maximum value signed 64.64-bit fixed point number may have. */ int128 private constant MAX_64x64 = 0x7FFFFFFFFFFFFFF...
/** * Smart contract library of mathematical functions operating with signed * 64.64-bit fixed point numbers. Signed 64.64-bit fixed point number is * basically a simple fraction whose numerator is signed 128-bit integer and * denominator is 2^64. As long as denominator is always the same, there is no * nee...
NatSpecMultiLine
log_2
function log_2 (int128 x) internal pure returns (int128) { require (x > 0); int256 msb = 0; int256 xc = x; if (xc >= 0x10000000000000000) { xc >>= 64; msb += 64; } if (xc >= 0x100000000) { xc >>= 32; msb += 32; } if (xc >= 0x10000) { xc >>= 16; msb += 16; } if (xc >= 0x100) { xc >>= 8; msb += 8; ...
/** * Calculate binary logarithm of x. Revert if x <= 0. * * @param x signed 64.64-bit fixed point number * @return signed 64.64-bit fixed point number */
NatSpecMultiLine
v0.5.17+commit.d19bba13
Unknown
bzzr://44f9869efe6cff5c5f543e2191ede97c1cdac7b3bccb186e17921ad8921ec0be
{ "func_code_index": [ 11592, 12377 ] }
10,201
Component
Component.sol
0x4ab3d420504cfb1188ce3b805e9c3c32c2531f2e
Solidity
ABDKMath64x64
library ABDKMath64x64 { /** * Minimum value signed 64.64-bit fixed point number may have. */ int128 private constant MIN_64x64 = -0x80000000000000000000000000000000; /** * Maximum value signed 64.64-bit fixed point number may have. */ int128 private constant MAX_64x64 = 0x7FFFFFFFFFFFFFF...
/** * Smart contract library of mathematical functions operating with signed * 64.64-bit fixed point numbers. Signed 64.64-bit fixed point number is * basically a simple fraction whose numerator is signed 128-bit integer and * denominator is 2^64. As long as denominator is always the same, there is no * nee...
NatSpecMultiLine
ln
function ln (int128 x) internal pure returns (int128) { require (x > 0); return int128 ( uint256 (log_2 (x)) * 0xB17217F7D1CF79ABC9E3B39803F2F6AF >> 128); }
/** * Calculate natural logarithm of x. Revert if x <= 0. * * @param x signed 64.64-bit fixed point number * @return signed 64.64-bit fixed point number */
NatSpecMultiLine
v0.5.17+commit.d19bba13
Unknown
bzzr://44f9869efe6cff5c5f543e2191ede97c1cdac7b3bccb186e17921ad8921ec0be
{ "func_code_index": [ 12560, 12743 ] }
10,202
Component
Component.sol
0x4ab3d420504cfb1188ce3b805e9c3c32c2531f2e
Solidity
ABDKMath64x64
library ABDKMath64x64 { /** * Minimum value signed 64.64-bit fixed point number may have. */ int128 private constant MIN_64x64 = -0x80000000000000000000000000000000; /** * Maximum value signed 64.64-bit fixed point number may have. */ int128 private constant MAX_64x64 = 0x7FFFFFFFFFFFFFF...
/** * Smart contract library of mathematical functions operating with signed * 64.64-bit fixed point numbers. Signed 64.64-bit fixed point number is * basically a simple fraction whose numerator is signed 128-bit integer and * denominator is 2^64. As long as denominator is always the same, there is no * nee...
NatSpecMultiLine
exp_2
function exp_2 (int128 x) internal pure returns (int128) { require (x < 0x400000000000000000); // Overflow if (x < -0x400000000000000000) return 0; // Underflow uint256 result = 0x80000000000000000000000000000000; if (x & 0x8000000000000000 > 0) result = result * 0x16A09E667F3BCC908B2FB1366EA957D...
/** * Calculate binary exponent of x. Revert on overflow. * * @param x signed 64.64-bit fixed point number * @return signed 64.64-bit fixed point number */
NatSpecMultiLine
v0.5.17+commit.d19bba13
Unknown
bzzr://44f9869efe6cff5c5f543e2191ede97c1cdac7b3bccb186e17921ad8921ec0be
{ "func_code_index": [ 12926, 19583 ] }
10,203
Component
Component.sol
0x4ab3d420504cfb1188ce3b805e9c3c32c2531f2e
Solidity
ABDKMath64x64
library ABDKMath64x64 { /** * Minimum value signed 64.64-bit fixed point number may have. */ int128 private constant MIN_64x64 = -0x80000000000000000000000000000000; /** * Maximum value signed 64.64-bit fixed point number may have. */ int128 private constant MAX_64x64 = 0x7FFFFFFFFFFFFFF...
/** * Smart contract library of mathematical functions operating with signed * 64.64-bit fixed point numbers. Signed 64.64-bit fixed point number is * basically a simple fraction whose numerator is signed 128-bit integer and * denominator is 2^64. As long as denominator is always the same, there is no * nee...
NatSpecMultiLine
exp
function exp (int128 x) internal pure returns (int128) { require (x < 0x400000000000000000); // Overflow if (x < -0x400000000000000000) return 0; // Underflow return exp_2 ( int128 (int256 (x) * 0x171547652B82FE1777D0FFDA0D23A7D12 >> 128)); }
/** * Calculate natural exponent of x. Revert on overflow. * * @param x signed 64.64-bit fixed point number * @return signed 64.64-bit fixed point number */
NatSpecMultiLine
v0.5.17+commit.d19bba13
Unknown
bzzr://44f9869efe6cff5c5f543e2191ede97c1cdac7b3bccb186e17921ad8921ec0be
{ "func_code_index": [ 19767, 20043 ] }
10,204
Component
Component.sol
0x4ab3d420504cfb1188ce3b805e9c3c32c2531f2e
Solidity
ABDKMath64x64
library ABDKMath64x64 { /** * Minimum value signed 64.64-bit fixed point number may have. */ int128 private constant MIN_64x64 = -0x80000000000000000000000000000000; /** * Maximum value signed 64.64-bit fixed point number may have. */ int128 private constant MAX_64x64 = 0x7FFFFFFFFFFFFFF...
/** * Smart contract library of mathematical functions operating with signed * 64.64-bit fixed point numbers. Signed 64.64-bit fixed point number is * basically a simple fraction whose numerator is signed 128-bit integer and * denominator is 2^64. As long as denominator is always the same, there is no * nee...
NatSpecMultiLine
divuu
function divuu (uint256 x, uint256 y) private pure returns (uint128) { require (y != 0); uint256 result; if (x <= 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF) result = (x << 64) / y; else { uint256 msb = 192; uint256 xc = x >> 192; if (xc >= 0x100000000) { xc >>= 32; msb += 32...
/** * Calculate x / y rounding towards zero, where x and y are unsigned 256-bit * integer numbers. Revert on overflow or when y is zero. * * @param x unsigned 256-bit integer number * @param y unsigned 256-bit integer number * @return unsigned 64.64-bit fixed point number */
NatSpecMultiLine
v0.5.17+commit.d19bba13
Unknown
bzzr://44f9869efe6cff5c5f543e2191ede97c1cdac7b3bccb186e17921ad8921ec0be
{ "func_code_index": [ 20354, 21614 ] }
10,205
Component
Component.sol
0x4ab3d420504cfb1188ce3b805e9c3c32c2531f2e
Solidity
ABDKMath64x64
library ABDKMath64x64 { /** * Minimum value signed 64.64-bit fixed point number may have. */ int128 private constant MIN_64x64 = -0x80000000000000000000000000000000; /** * Maximum value signed 64.64-bit fixed point number may have. */ int128 private constant MAX_64x64 = 0x7FFFFFFFFFFFFFF...
/** * Smart contract library of mathematical functions operating with signed * 64.64-bit fixed point numbers. Signed 64.64-bit fixed point number is * basically a simple fraction whose numerator is signed 128-bit integer and * denominator is 2^64. As long as denominator is always the same, there is no * nee...
NatSpecMultiLine
powu
function powu (uint256 x, uint256 y) private pure returns (uint256) { if (y == 0) return 0x80000000000000000000000000000000; else if (x == 0) return 0; else { int256 msb = 0; uint256 xc = x; if (xc >= 0x100000000000000000000000000000000) { xc >>= 128; msb += 128; } if (xc >= 0x1000000000000...
/** * Calculate x^y assuming 0^0 is 1, where x is unsigned 129.127 fixed point * number and y is unsigned 256-bit integer number. Revert on overflow. * * @param x unsigned 129.127-bit fixed point number * @param y uint256 value * @return unsigned 129.127-bit fixed point number */
NatSpecMultiLine
v0.5.17+commit.d19bba13
Unknown
bzzr://44f9869efe6cff5c5f543e2191ede97c1cdac7b3bccb186e17921ad8921ec0be
{ "func_code_index": [ 21930, 23670 ] }
10,206
Component
Component.sol
0x4ab3d420504cfb1188ce3b805e9c3c32c2531f2e
Solidity
ABDKMath64x64
library ABDKMath64x64 { /** * Minimum value signed 64.64-bit fixed point number may have. */ int128 private constant MIN_64x64 = -0x80000000000000000000000000000000; /** * Maximum value signed 64.64-bit fixed point number may have. */ int128 private constant MAX_64x64 = 0x7FFFFFFFFFFFFFF...
/** * Smart contract library of mathematical functions operating with signed * 64.64-bit fixed point numbers. Signed 64.64-bit fixed point number is * basically a simple fraction whose numerator is signed 128-bit integer and * denominator is 2^64. As long as denominator is always the same, there is no * nee...
NatSpecMultiLine
sqrtu
function sqrtu (uint256 x, uint256 r) private pure returns (uint128) { if (x == 0) return 0; else { require (r > 0); while (true) { uint256 rr = x / r; if (r == rr || r + 1 == rr) return uint128 (r); else if (r == rr + 1) return uint128 (rr); r = r + rr + 1 >> 1; } } ...
/** * Calculate sqrt (x) rounding down, where x is unsigned 256-bit integer * number. * * @param x unsigned 256-bit integer number * @return unsigned 128-bit integer number */
NatSpecMultiLine
v0.5.17+commit.d19bba13
Unknown
bzzr://44f9869efe6cff5c5f543e2191ede97c1cdac7b3bccb186e17921ad8921ec0be
{ "func_code_index": [ 23876, 24223 ] }
10,207
Component
Component.sol
0x4ab3d420504cfb1188ce3b805e9c3c32c2531f2e
Solidity
UnsafeMath64x64
library UnsafeMath64x64 { /** * Calculate x * y rounding down. * * @param x signed 64.64-bit fixed point number * @param y signed 64.64-bit fixed point number * @return signed 64.64-bit fixed point number */ function us_mul (int128 x, int128 y) internal pure returns (int128) { int...
us_mul
function us_mul (int128 x, int128 y) internal pure returns (int128) { int256 result = int256(x) * y >> 64; return int128 (result); }
/** * Calculate x * y rounding down. * * @param x signed 64.64-bit fixed point number * @param y signed 64.64-bit fixed point number * @return signed 64.64-bit fixed point number */
NatSpecMultiLine
v0.5.17+commit.d19bba13
Unknown
bzzr://44f9869efe6cff5c5f543e2191ede97c1cdac7b3bccb186e17921ad8921ec0be
{ "func_code_index": [ 240, 388 ] }
10,208
Component
Component.sol
0x4ab3d420504cfb1188ce3b805e9c3c32c2531f2e
Solidity
UnsafeMath64x64
library UnsafeMath64x64 { /** * Calculate x * y rounding down. * * @param x signed 64.64-bit fixed point number * @param y signed 64.64-bit fixed point number * @return signed 64.64-bit fixed point number */ function us_mul (int128 x, int128 y) internal pure returns (int128) { int...
us_div
function us_div (int128 x, int128 y) internal pure returns (int128) { int256 result = (int256 (x) << 64) / y; return int128 (result); }
/** * Calculate x / y rounding towards zero. Revert on overflow or when y is * zero. * * @param x signed 64.64-bit fixed point number * @param y signed 64.64-bit fixed point number * @return signed 64.64-bit fixed point number */
NatSpecMultiLine
v0.5.17+commit.d19bba13
Unknown
bzzr://44f9869efe6cff5c5f543e2191ede97c1cdac7b3bccb186e17921ad8921ec0be
{ "func_code_index": [ 655, 806 ] }
10,209
Component
Component.sol
0x4ab3d420504cfb1188ce3b805e9c3c32c2531f2e
Solidity
Components
library Components { using ABDKMath64x64 for int128; event Approval(address indexed _owner, address indexed spender, uint256 value); event Transfer(address indexed from, address indexed to, uint256 value); function add(uint x, uint y, string memory errorMessage) private pure returns (uint z) {...
// This program is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. // This program is distributed in the hope that it will be useful, /...
LineComment
transfer
function transfer(ComponentStorage.Component storage component, address recipient, uint256 amount) external returns (bool) { _transfer(component, msg.sender, 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.17+commit.d19bba13
Unknown
bzzr://44f9869efe6cff5c5f543e2191ede97c1cdac7b3bccb186e17921ad8921ec0be
{ "func_code_index": [ 739, 959 ] }
10,210
Component
Component.sol
0x4ab3d420504cfb1188ce3b805e9c3c32c2531f2e
Solidity
Components
library Components { using ABDKMath64x64 for int128; event Approval(address indexed _owner, address indexed spender, uint256 value); event Transfer(address indexed from, address indexed to, uint256 value); function add(uint x, uint y, string memory errorMessage) private pure returns (uint z) {...
// This program is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. // This program is distributed in the hope that it will be useful, /...
LineComment
approve
function approve(ComponentStorage.Component storage component, address spender, uint256 amount) external returns (bool) { _approve(component, msg.sender, spender, amount); return true; }
/** * @dev See {IERC20-approve}. * * Requirements: * * - `spender` cannot be the zero address. */
NatSpecMultiLine
v0.5.17+commit.d19bba13
Unknown
bzzr://44f9869efe6cff5c5f543e2191ede97c1cdac7b3bccb186e17921ad8921ec0be
{ "func_code_index": [ 1101, 1315 ] }
10,211
Component
Component.sol
0x4ab3d420504cfb1188ce3b805e9c3c32c2531f2e
Solidity
Components
library Components { using ABDKMath64x64 for int128; event Approval(address indexed _owner, address indexed spender, uint256 value); event Transfer(address indexed from, address indexed to, uint256 value); function add(uint x, uint y, string memory errorMessage) private pure returns (uint z) {...
// This program is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. // This program is distributed in the hope that it will be useful, /...
LineComment
transferFrom
function transferFrom(ComponentStorage.Component storage component, address sender, address recipient, uint256 amount) external returns (bool) { _transfer(component, sender, recipient, amount); _approve(component, sender, msg.sender, sub(component.allowances[sender][msg.sender], amount, "Component/insufficien...
/** * @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.17+commit.d19bba13
Unknown
bzzr://44f9869efe6cff5c5f543e2191ede97c1cdac7b3bccb186e17921ad8921ec0be
{ "func_code_index": [ 1781, 2158 ] }
10,212
Component
Component.sol
0x4ab3d420504cfb1188ce3b805e9c3c32c2531f2e
Solidity
Components
library Components { using ABDKMath64x64 for int128; event Approval(address indexed _owner, address indexed spender, uint256 value); event Transfer(address indexed from, address indexed to, uint256 value); function add(uint x, uint y, string memory errorMessage) private pure returns (uint z) {...
// This program is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. // This program is distributed in the hope that it will be useful, /...
LineComment
increaseAllowance
function increaseAllowance(ComponentStorage.Component storage component, address spender, uint256 addedValue) external returns (bool) { _approve(component, msg.sender, spender, add(component.allowances[msg.sender][spender], addedValue, "Component/approval-overflow")); 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.17+commit.d19bba13
Unknown
bzzr://44f9869efe6cff5c5f543e2191ede97c1cdac7b3bccb186e17921ad8921ec0be
{ "func_code_index": [ 2562, 2873 ] }
10,213
Component
Component.sol
0x4ab3d420504cfb1188ce3b805e9c3c32c2531f2e
Solidity
Components
library Components { using ABDKMath64x64 for int128; event Approval(address indexed _owner, address indexed spender, uint256 value); event Transfer(address indexed from, address indexed to, uint256 value); function add(uint x, uint y, string memory errorMessage) private pure returns (uint z) {...
// This program is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. // This program is distributed in the hope that it will be useful, /...
LineComment
decreaseAllowance
function decreaseAllowance(ComponentStorage.Component storage component, address spender, uint256 subtractedValue) external returns (bool) { _approve(component, msg.sender, spender, sub(component.allowances[msg.sender][spender], subtractedValue, "Component/allowance-decrease-underflow")); 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.17+commit.d19bba13
Unknown
bzzr://44f9869efe6cff5c5f543e2191ede97c1cdac7b3bccb186e17921ad8921ec0be
{ "func_code_index": [ 3371, 3703 ] }
10,214
Component
Component.sol
0x4ab3d420504cfb1188ce3b805e9c3c32c2531f2e
Solidity
Components
library Components { using ABDKMath64x64 for int128; event Approval(address indexed _owner, address indexed spender, uint256 value); event Transfer(address indexed from, address indexed to, uint256 value); function add(uint x, uint y, string memory errorMessage) private pure returns (uint z) {...
// This program is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. // This program is distributed in the hope that it will be useful, /...
LineComment
_transfer
function _transfer(ComponentStorage.Component storage component, address sender, address recipient, uint256 amount) private { require(sender != address(0), "ERC20: transfer from the zero address"); require(recipient != address(0), "ERC20: transfer to the zero address"); component.balances[sender] = sub...
/** * @dev Moves tokens `amount` from `sender` to `recipient`. * * This is public 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.17+commit.d19bba13
Unknown
bzzr://44f9869efe6cff5c5f543e2191ede97c1cdac7b3bccb186e17921ad8921ec0be
{ "func_code_index": [ 4186, 4768 ] }
10,215
Component
Component.sol
0x4ab3d420504cfb1188ce3b805e9c3c32c2531f2e
Solidity
Components
library Components { using ABDKMath64x64 for int128; event Approval(address indexed _owner, address indexed spender, uint256 value); event Transfer(address indexed from, address indexed to, uint256 value); function add(uint x, uint y, string memory errorMessage) private pure returns (uint z) {...
// This program is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. // This program is distributed in the hope that it will be useful, /...
LineComment
_approve
function _approve(ComponentStorage.Component storage component, address _owner, address spender, uint256 amount) private { require(_owner != address(0), "ERC20: approve from the zero address"); require(spender != address(0), "ERC20: approve to the zero address"); component.allowances[_owner][spender] =...
/** * @dev Sets `amount` as the allowance of `spender` over the `_owner`s tokens. * * This is public 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.17+commit.d19bba13
Unknown
bzzr://44f9869efe6cff5c5f543e2191ede97c1cdac7b3bccb186e17921ad8921ec0be
{ "func_code_index": [ 5205, 5606 ] }
10,216
Component
Component.sol
0x4ab3d420504cfb1188ce3b805e9c3c32c2531f2e
Solidity
Component
contract Component is ComponentStorage { event Approval(address indexed _owner, address indexed spender, uint256 value); event ParametersSet(uint256 alpha, uint256 beta, uint256 delta, uint256 epsilon, uint256 lambda); event AssetIncluded(address indexed numeraire, address indexed reserve, uint wei...
// This program is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. // This program is distributed in the hope that it will be useful, /...
LineComment
setParams
function setParams ( uint _alpha, uint _beta, uint _feeAtHalt, uint _epsilon, uint _lambda, uint _sigma, address _protocol ) external onlyOwner { Orchestrator.setParams(component, _alpha, _beta, _feeAtHalt, _epsilon, _lambda, _sigma, _protocol); }
/// @notice sets the parameters for the pool /// @param _alpha the value for alpha (halt threshold) must be less than or equal to 1 and greater than 0 /// @param _beta the value for beta must be less than alpha and greater than 0 /// @param _feeAtHalt the maximum value for the fee at the halt point /// @param _epsilon ...
NatSpecSingleLine
v0.5.17+commit.d19bba13
Unknown
bzzr://44f9869efe6cff5c5f543e2191ede97c1cdac7b3bccb186e17921ad8921ec0be
{ "func_code_index": [ 3189, 3527 ] }
10,217
Component
Component.sol
0x4ab3d420504cfb1188ce3b805e9c3c32c2531f2e
Solidity
Component
contract Component is ComponentStorage { event Approval(address indexed _owner, address indexed spender, uint256 value); event ParametersSet(uint256 alpha, uint256 beta, uint256 delta, uint256 epsilon, uint256 lambda); event AssetIncluded(address indexed numeraire, address indexed reserve, uint wei...
// This program is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. // This program is distributed in the hope that it will be useful, /...
LineComment
excludeDerivative
function excludeDerivative ( address _derivative ) external onlyOwner { for (uint i = 0; i < numeraires.length; i++) { if (_derivative == numeraires[i]) revert("Component/cannot-delete-numeraire"); if (_derivative == reserves[i]) revert("Component/cannot-delete-reserve"); } ...
/// @notice excludes an assimilator from the component /// @param _derivative the address of the assimilator to exclude
NatSpecSingleLine
v0.5.17+commit.d19bba13
Unknown
bzzr://44f9869efe6cff5c5f543e2191ede97c1cdac7b3bccb186e17921ad8921ec0be
{ "func_code_index": [ 3660, 4067 ] }
10,218
Component
Component.sol
0x4ab3d420504cfb1188ce3b805e9c3c32c2531f2e
Solidity
Component
contract Component is ComponentStorage { event Approval(address indexed _owner, address indexed spender, uint256 value); event ParametersSet(uint256 alpha, uint256 beta, uint256 delta, uint256 epsilon, uint256 lambda); event AssetIncluded(address indexed numeraire, address indexed reserve, uint wei...
// This program is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. // This program is distributed in the hope that it will be useful, /...
LineComment
viewComponent
function viewComponent() external view returns ( uint alpha_, uint beta_, uint delta_, uint epsilon_, uint lambda_ ) { return Orchestrator.viewComponent(component); }
/// @notice view the current parameters of the component /// @return alpha_ the current alpha value /// @return beta_ the current beta value /// @return delta_ the current delta value /// @return epsilon_ the current epsilon value /// @return lambda_ the current lambda value /// @return omega_ the current omega value
NatSpecSingleLine
v0.5.17+commit.d19bba13
Unknown
bzzr://44f9869efe6cff5c5f543e2191ede97c1cdac7b3bccb186e17921ad8921ec0be
{ "func_code_index": [ 4424, 4663 ] }
10,219
Component
Component.sol
0x4ab3d420504cfb1188ce3b805e9c3c32c2531f2e
Solidity
Component
contract Component is ComponentStorage { event Approval(address indexed _owner, address indexed spender, uint256 value); event ParametersSet(uint256 alpha, uint256 beta, uint256 delta, uint256 epsilon, uint256 lambda); event AssetIncluded(address indexed numeraire, address indexed reserve, uint wei...
// This program is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. // This program is distributed in the hope that it will be useful, /...
LineComment
originSwap
function originSwap ( address _origin, address _target, uint _originAmount, uint _minTargetAmount, uint _deadline ) external deadline(_deadline) transactable nonReentrant returns ( uint targetAmount_ ) { targetAmount_ = Swaps.originSwap(component, _origin, _target, _originAmount, ...
/// @author james foley http://github.com/realisation /// @notice swap a dynamic origin amount for a fixed target amount /// @param _origin the address of the origin /// @param _target the address of the target /// @param _originAmount the origin amount /// @param _minTargetAmount the minimum target amount /// @param _...
NatSpecSingleLine
v0.5.17+commit.d19bba13
Unknown
bzzr://44f9869efe6cff5c5f543e2191ede97c1cdac7b3bccb186e17921ad8921ec0be
{ "func_code_index": [ 5540, 6013 ] }
10,220
Component
Component.sol
0x4ab3d420504cfb1188ce3b805e9c3c32c2531f2e
Solidity
Component
contract Component is ComponentStorage { event Approval(address indexed _owner, address indexed spender, uint256 value); event ParametersSet(uint256 alpha, uint256 beta, uint256 delta, uint256 epsilon, uint256 lambda); event AssetIncluded(address indexed numeraire, address indexed reserve, uint wei...
// This program is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. // This program is distributed in the hope that it will be useful, /...
LineComment
viewOriginSwap
function viewOriginSwap ( address _origin, address _target, uint _originAmount ) external view transactable returns ( uint targetAmount_ ) { targetAmount_ = Swaps.viewOriginSwap(component, _origin, _target, _originAmount); }
/// @author james foley http://github.com/realisation /// @notice view how much target amount a fixed origin amount will swap for /// @param _origin the address of the origin /// @param _target the address of the target /// @param _originAmount the origin amount /// @return targetAmount_ the target amount that would ha...
NatSpecSingleLine
v0.5.17+commit.d19bba13
Unknown
bzzr://44f9869efe6cff5c5f543e2191ede97c1cdac7b3bccb186e17921ad8921ec0be
{ "func_code_index": [ 6903, 7196 ] }
10,221
Component
Component.sol
0x4ab3d420504cfb1188ce3b805e9c3c32c2531f2e
Solidity
Component
contract Component is ComponentStorage { event Approval(address indexed _owner, address indexed spender, uint256 value); event ParametersSet(uint256 alpha, uint256 beta, uint256 delta, uint256 epsilon, uint256 lambda); event AssetIncluded(address indexed numeraire, address indexed reserve, uint wei...
// This program is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. // This program is distributed in the hope that it will be useful, /...
LineComment
targetSwap
function targetSwap ( address _origin, address _target, uint _maxOriginAmount, uint _targetAmount, uint _deadline ) external deadline(_deadline) transactable nonReentrant returns ( uint originAmount_ ) { originAmount_ = Swaps.targetSwap(component, _origin, _target, _targetAmount, ...
/// @author james foley http://github.com/realisation /// @notice swap a dynamic origin amount for a fixed target amount /// @param _origin the address of the origin /// @param _target the address of the target /// @param _maxOriginAmount the maximum origin amount /// @param _targetAmount the target amount /// @param _...
NatSpecSingleLine
v0.5.17+commit.d19bba13
Unknown
bzzr://44f9869efe6cff5c5f543e2191ede97c1cdac7b3bccb186e17921ad8921ec0be
{ "func_code_index": [ 7716, 8189 ] }
10,222
Component
Component.sol
0x4ab3d420504cfb1188ce3b805e9c3c32c2531f2e
Solidity
Component
contract Component is ComponentStorage { event Approval(address indexed _owner, address indexed spender, uint256 value); event ParametersSet(uint256 alpha, uint256 beta, uint256 delta, uint256 epsilon, uint256 lambda); event AssetIncluded(address indexed numeraire, address indexed reserve, uint wei...
// This program is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. // This program is distributed in the hope that it will be useful, /...
LineComment
viewTargetSwap
function viewTargetSwap ( address _origin, address _target, uint _targetAmount ) external view transactable returns ( uint originAmount_ ) { originAmount_ = Swaps.viewTargetSwap(component, _origin, _target, _targetAmount); }
/// @author james foley http://github.com/realisation /// @notice view how much of the origin currency the target currency will take /// @param _origin the address of the origin /// @param _target the address of the target /// @param _targetAmount the target amount /// @return originAmount_ the amount of target that ha...
NatSpecSingleLine
v0.5.17+commit.d19bba13
Unknown
bzzr://44f9869efe6cff5c5f543e2191ede97c1cdac7b3bccb186e17921ad8921ec0be
{ "func_code_index": [ 8572, 8865 ] }
10,223
Component
Component.sol
0x4ab3d420504cfb1188ce3b805e9c3c32c2531f2e
Solidity
Component
contract Component is ComponentStorage { event Approval(address indexed _owner, address indexed spender, uint256 value); event ParametersSet(uint256 alpha, uint256 beta, uint256 delta, uint256 epsilon, uint256 lambda); event AssetIncluded(address indexed numeraire, address indexed reserve, uint wei...
// This program is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. // This program is distributed in the hope that it will be useful, /...
LineComment
selectiveDeposit
function selectiveDeposit ( address[] calldata _derivatives, uint[] calldata _amounts, uint _minComponents, uint _deadline ) external deadline(_deadline) transactable nonReentrant returns ( uint componentsMinted_ ) { componentsMinted_ = SelectiveLiquidity.selectiveDeposit(component, _d...
/// @author james foley http://github.com/realisation /// @notice selectively deposit any supported stablecoin flavor into the contract in return for corresponding amount of component tokens /// @param _derivatives an array containing the addresses of the flavors being deposited into /// @param _amounts an array contai...
NatSpecSingleLine
v0.5.17+commit.d19bba13
Unknown
bzzr://44f9869efe6cff5c5f543e2191ede97c1cdac7b3bccb186e17921ad8921ec0be
{ "func_code_index": [ 9572, 9976 ] }
10,224
Component
Component.sol
0x4ab3d420504cfb1188ce3b805e9c3c32c2531f2e
Solidity
Component
contract Component is ComponentStorage { event Approval(address indexed _owner, address indexed spender, uint256 value); event ParametersSet(uint256 alpha, uint256 beta, uint256 delta, uint256 epsilon, uint256 lambda); event AssetIncluded(address indexed numeraire, address indexed reserve, uint wei...
// This program is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. // This program is distributed in the hope that it will be useful, /...
LineComment
viewSelectiveDeposit
function viewSelectiveDeposit ( address[] calldata _derivatives, uint[] calldata _amounts ) external view transactable returns ( uint componentsToMint_ ) { componentsToMint_ = SelectiveLiquidity.viewSelectiveDeposit(component, _derivatives, _amounts); }
/// @author james folew http://github.com/realisation /// @notice view how many component tokens a deposit will mint /// @param _derivatives an array containing the addresses of the flavors being deposited into /// @param _amounts an array containing the values of the flavors you wish to deposit into the contract. each...
NatSpecSingleLine
v0.5.17+commit.d19bba13
Unknown
bzzr://44f9869efe6cff5c5f543e2191ede97c1cdac7b3bccb186e17921ad8921ec0be
{ "func_code_index": [ 10496, 10809 ] }
10,225
Component
Component.sol
0x4ab3d420504cfb1188ce3b805e9c3c32c2531f2e
Solidity
Component
contract Component is ComponentStorage { event Approval(address indexed _owner, address indexed spender, uint256 value); event ParametersSet(uint256 alpha, uint256 beta, uint256 delta, uint256 epsilon, uint256 lambda); event AssetIncluded(address indexed numeraire, address indexed reserve, uint wei...
// This program is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. // This program is distributed in the hope that it will be useful, /...
LineComment
proportionalDeposit
function proportionalDeposit ( uint _deposit, uint _deadline ) external deadline(_deadline) transactable nonReentrant returns ( uint componentsMinted_, uint[] memory deposits_ ) { return ProportionalLiquidity.proportionalDeposit(component, _deposit); }
/// @author james foley http://github.com/realisation /// @notice deposit into the pool with no slippage from the numeraire assets the pool supports /// @param _deposit the full amount you want to deposit into the pool which will be divided up evenly amongst the numeraire assets of the pool /// @return componentsToMin...
NatSpecSingleLine
v0.5.17+commit.d19bba13
Unknown
bzzr://44f9869efe6cff5c5f543e2191ede97c1cdac7b3bccb186e17921ad8921ec0be
{ "func_code_index": [ 11286, 11607 ] }
10,226
Component
Component.sol
0x4ab3d420504cfb1188ce3b805e9c3c32c2531f2e
Solidity
Component
contract Component is ComponentStorage { event Approval(address indexed _owner, address indexed spender, uint256 value); event ParametersSet(uint256 alpha, uint256 beta, uint256 delta, uint256 epsilon, uint256 lambda); event AssetIncluded(address indexed numeraire, address indexed reserve, uint wei...
// This program is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. // This program is distributed in the hope that it will be useful, /...
LineComment
viewProportionalDeposit
function viewProportionalDeposit ( uint _deposit ) external view transactable returns ( uint componentsToMint_, uint[] memory depositsToMake_ ) { return ProportionalLiquidity.viewProportionalDeposit(component, _deposit); }
/// @author james foley http://github.com/realisation /// @notice view deposits and components minted a given deposit would return /// @param _deposit the full amount of stablecoins you want to deposit. Divided evenly according to the prevailing proportions of the numeraire assets of the pool /// @return componentsToMi...
NatSpecSingleLine
v0.5.17+commit.d19bba13
Unknown
bzzr://44f9869efe6cff5c5f543e2191ede97c1cdac7b3bccb186e17921ad8921ec0be
{ "func_code_index": [ 12085, 12367 ] }
10,227
Component
Component.sol
0x4ab3d420504cfb1188ce3b805e9c3c32c2531f2e
Solidity
Component
contract Component is ComponentStorage { event Approval(address indexed _owner, address indexed spender, uint256 value); event ParametersSet(uint256 alpha, uint256 beta, uint256 delta, uint256 epsilon, uint256 lambda); event AssetIncluded(address indexed numeraire, address indexed reserve, uint wei...
// This program is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. // This program is distributed in the hope that it will be useful, /...
LineComment
selectiveWithdraw
function selectiveWithdraw ( address[] calldata _derivatives, uint[] calldata _amounts, uint _maxComponents, uint _deadline ) external deadline(_deadline) transactable nonReentrant returns ( uint componentsBurned_ ) { componentsBurned_ = SelectiveLiquidity.selectiveWithdraw(component, ...
/// @author james foley http://github.com/realisation /// @notice selectively withdrawal any supported stablecoin flavor from the contract by burning a corresponding amount of component tokens /// @param _derivatives an array of flavors to withdraw from the reserves /// @param _amounts an array of amounts to withdraw t...
NatSpecSingleLine
v0.5.17+commit.d19bba13
Unknown
bzzr://44f9869efe6cff5c5f543e2191ede97c1cdac7b3bccb186e17921ad8921ec0be
{ "func_code_index": [ 13029, 13435 ] }
10,228
Component
Component.sol
0x4ab3d420504cfb1188ce3b805e9c3c32c2531f2e
Solidity
Component
contract Component is ComponentStorage { event Approval(address indexed _owner, address indexed spender, uint256 value); event ParametersSet(uint256 alpha, uint256 beta, uint256 delta, uint256 epsilon, uint256 lambda); event AssetIncluded(address indexed numeraire, address indexed reserve, uint wei...
// This program is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. // This program is distributed in the hope that it will be useful, /...
LineComment
viewSelectiveWithdraw
function viewSelectiveWithdraw ( address[] calldata _derivatives, uint[] calldata _amounts ) external view transactable returns ( uint componentsToBurn_ ) { componentsToBurn_ = SelectiveLiquidity.viewSelectiveWithdraw(component, _derivatives, _amounts); }
/// @author james foley http://github.com/realisation /// @notice view how many component tokens a withdraw will consume /// @param _derivatives an array of flavors to withdraw from the reserves /// @param _amounts an array of amounts to withdraw that maps to _flavors /// @return componentsBurned_ the corresponding amo...
NatSpecSingleLine
v0.5.17+commit.d19bba13
Unknown
bzzr://44f9869efe6cff5c5f543e2191ede97c1cdac7b3bccb186e17921ad8921ec0be
{ "func_code_index": [ 13861, 14176 ] }
10,229
Component
Component.sol
0x4ab3d420504cfb1188ce3b805e9c3c32c2531f2e
Solidity
Component
contract Component is ComponentStorage { event Approval(address indexed _owner, address indexed spender, uint256 value); event ParametersSet(uint256 alpha, uint256 beta, uint256 delta, uint256 epsilon, uint256 lambda); event AssetIncluded(address indexed numeraire, address indexed reserve, uint wei...
// This program is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. // This program is distributed in the hope that it will be useful, /...
LineComment
proportionalWithdraw
function proportionalWithdraw ( uint _componentsToBurn, uint _deadline ) external deadline(_deadline) unpartitioned nonReentrant returns ( uint[] memory withdrawals_ ) { return ProportionalLiquidity.proportionalWithdraw(component, _componentsToBurn); }
/// @author james foley http://github.com/realisation /// @notice withdrawas amount of component tokens from the the pool equally from the numeraire assets of the pool with no slippage /// @param _componentsToBurn the full amount you want to withdraw from the pool which will be withdrawn from evenly amongst the num...
NatSpecSingleLine
v0.5.17+commit.d19bba13
Unknown
bzzr://44f9869efe6cff5c5f543e2191ede97c1cdac7b3bccb186e17921ad8921ec0be
{ "func_code_index": [ 14625, 14937 ] }
10,230
Component
Component.sol
0x4ab3d420504cfb1188ce3b805e9c3c32c2531f2e
Solidity
Component
contract Component is ComponentStorage { event Approval(address indexed _owner, address indexed spender, uint256 value); event ParametersSet(uint256 alpha, uint256 beta, uint256 delta, uint256 epsilon, uint256 lambda); event AssetIncluded(address indexed numeraire, address indexed reserve, uint wei...
// This program is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. // This program is distributed in the hope that it will be useful, /...
LineComment
viewProportionalWithdraw
function viewProportionalWithdraw ( uint _componentsToBurn ) external view unpartitioned returns ( uint[] memory withdrawalsToHappen_ ) { return ProportionalLiquidity.viewProportionalWithdraw(component, _componentsToBurn); }
/// @author james foley http://github.com/realisation /// @notice withdrawals amount of component tokens from the the pool equally from the numeraire assets of the pool with no slippage /// @param _componentsToBurn the full amount you want to withdraw from the pool which will be withdrawn from evenly amongst the nu...
NatSpecSingleLine
v0.5.17+commit.d19bba13
Unknown
bzzr://44f9869efe6cff5c5f543e2191ede97c1cdac7b3bccb186e17921ad8921ec0be
{ "func_code_index": [ 15761, 16036 ] }
10,231
Component
Component.sol
0x4ab3d420504cfb1188ce3b805e9c3c32c2531f2e
Solidity
Component
contract Component is ComponentStorage { event Approval(address indexed _owner, address indexed spender, uint256 value); event ParametersSet(uint256 alpha, uint256 beta, uint256 delta, uint256 epsilon, uint256 lambda); event AssetIncluded(address indexed numeraire, address indexed reserve, uint wei...
// This program is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. // This program is distributed in the hope that it will be useful, /...
LineComment
partitionedWithdraw
function partitionedWithdraw ( address[] calldata _tokens, uint256[] calldata _amounts ) external isPartitioned returns ( uint256[] memory withdrawals_ ) { return PartitionedLiquidity.partitionedWithdraw(component, partitionTickets, _tokens, _amounts); }
/// @author james foley http://github.com/realisation /// @notice withdraws amount of component tokens from the the pool equally from the numeraire assets of the pool with no slippage /// @param _tokens an array of the numeraire assets you will withdraw /// @param _amounts an array of the amounts in terms of partitio...
NatSpecSingleLine
v0.5.17+commit.d19bba13
Unknown
bzzr://44f9869efe6cff5c5f543e2191ede97c1cdac7b3bccb186e17921ad8921ec0be
{ "func_code_index": [ 16734, 17048 ] }
10,232
Component
Component.sol
0x4ab3d420504cfb1188ce3b805e9c3c32c2531f2e
Solidity
Component
contract Component is ComponentStorage { event Approval(address indexed _owner, address indexed spender, uint256 value); event ParametersSet(uint256 alpha, uint256 beta, uint256 delta, uint256 epsilon, uint256 lambda); event AssetIncluded(address indexed numeraire, address indexed reserve, uint wei...
// This program is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. // This program is distributed in the hope that it will be useful, /...
LineComment
viewPartitionClaims
function viewPartitionClaims ( address _addr ) external view isPartitioned returns ( uint[] memory claims_ ) { return PartitionedLiquidity.viewPartitionClaims(component, partitionTickets, _addr); }
/// @author james foley http://github.com/realisation /// @notice views the balance of the users partition ticket /// @param _addr the address whose balances in partitioned components to be seen /// @return claims_ the remaining claims in terms of partitioned components the address has in its partition ticket
NatSpecSingleLine
v0.5.17+commit.d19bba13
Unknown
bzzr://44f9869efe6cff5c5f543e2191ede97c1cdac7b3bccb186e17921ad8921ec0be
{ "func_code_index": [ 17384, 17632 ] }
10,233
Component
Component.sol
0x4ab3d420504cfb1188ce3b805e9c3c32c2531f2e
Solidity
Component
contract Component is ComponentStorage { event Approval(address indexed _owner, address indexed spender, uint256 value); event ParametersSet(uint256 alpha, uint256 beta, uint256 delta, uint256 epsilon, uint256 lambda); event AssetIncluded(address indexed numeraire, address indexed reserve, uint wei...
// This program is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. // This program is distributed in the hope that it will be useful, /...
LineComment
transfer
function transfer ( address _recipient, uint _amount ) public nonReentrant returns ( bool success_ ) { require(!partitionTickets[msg.sender].initialized, "Component/no-transfers-once-partitioned"); success_ = Components.transfer(component, _recipient, _amount); }
/// @notice transfers component tokens /// @param _recipient the address of where to send the component tokens /// @param _amount the amount of component tokens to send /// @return success_ the success bool of the call
NatSpecSingleLine
v0.5.17+commit.d19bba13
Unknown
bzzr://44f9869efe6cff5c5f543e2191ede97c1cdac7b3bccb186e17921ad8921ec0be
{ "func_code_index": [ 17874, 18208 ] }
10,234
Component
Component.sol
0x4ab3d420504cfb1188ce3b805e9c3c32c2531f2e
Solidity
Component
contract Component is ComponentStorage { event Approval(address indexed _owner, address indexed spender, uint256 value); event ParametersSet(uint256 alpha, uint256 beta, uint256 delta, uint256 epsilon, uint256 lambda); event AssetIncluded(address indexed numeraire, address indexed reserve, uint wei...
// This program is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. // This program is distributed in the hope that it will be useful, /...
LineComment
transferFrom
function transferFrom ( address _sender, address _recipient, uint _amount ) public nonReentrant returns ( bool success_ ) { require(!partitionTickets[_sender].initialized, "Component/no-transfers-once-partitioned"); success_ = Components.transferFrom(component, _sender, _recipient, _...
/// @notice transfers component tokens from one address to another address /// @param _sender the account from which the component tokens will be sent /// @param _recipient the account to which the component tokens will be sent /// @param _amount the amount of component tokens to transfer /// @return success_ the succe...
NatSpecSingleLine
v0.5.17+commit.d19bba13
Unknown
bzzr://44f9869efe6cff5c5f543e2191ede97c1cdac7b3bccb186e17921ad8921ec0be
{ "func_code_index": [ 18576, 18950 ] }
10,235
Component
Component.sol
0x4ab3d420504cfb1188ce3b805e9c3c32c2531f2e
Solidity
Component
contract Component is ComponentStorage { event Approval(address indexed _owner, address indexed spender, uint256 value); event ParametersSet(uint256 alpha, uint256 beta, uint256 delta, uint256 epsilon, uint256 lambda); event AssetIncluded(address indexed numeraire, address indexed reserve, uint wei...
// This program is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. // This program is distributed in the hope that it will be useful, /...
LineComment
approve
function approve (address _spender, uint _amount) public nonReentrant returns (bool success_) { success_ = Components.approve(component, _spender, _amount); }
/// @notice approves a user to spend component tokens on their behalf /// @param _spender the account to allow to spend from msg.sender /// @param _amount the amount to specify the spender can spend /// @return success_ the success bool of this call
NatSpecSingleLine
v0.5.17+commit.d19bba13
Unknown
bzzr://44f9869efe6cff5c5f543e2191ede97c1cdac7b3bccb186e17921ad8921ec0be
{ "func_code_index": [ 19223, 19404 ] }
10,236
Component
Component.sol
0x4ab3d420504cfb1188ce3b805e9c3c32c2531f2e
Solidity
Component
contract Component is ComponentStorage { event Approval(address indexed _owner, address indexed spender, uint256 value); event ParametersSet(uint256 alpha, uint256 beta, uint256 delta, uint256 epsilon, uint256 lambda); event AssetIncluded(address indexed numeraire, address indexed reserve, uint wei...
// This program is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. // This program is distributed in the hope that it will be useful, /...
LineComment
balanceOf
function balanceOf ( address _account ) public view returns ( uint balance_ ) { balance_ = component.balances[_account]; }
/// @notice view the component token balance of a given account /// @param _account the account to view the balance of /// @return balance_ the component token ballance of the given account
NatSpecSingleLine
v0.5.17+commit.d19bba13
Unknown
bzzr://44f9869efe6cff5c5f543e2191ede97c1cdac7b3bccb186e17921ad8921ec0be
{ "func_code_index": [ 19612, 19785 ] }
10,237
Component
Component.sol
0x4ab3d420504cfb1188ce3b805e9c3c32c2531f2e
Solidity
Component
contract Component is ComponentStorage { event Approval(address indexed _owner, address indexed spender, uint256 value); event ParametersSet(uint256 alpha, uint256 beta, uint256 delta, uint256 epsilon, uint256 lambda); event AssetIncluded(address indexed numeraire, address indexed reserve, uint wei...
// This program is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. // This program is distributed in the hope that it will be useful, /...
LineComment
totalSupply
function totalSupply () public view returns (uint totalSupply_) { totalSupply_ = component.totalSupply; }
/// @notice views the total component supply of the pool /// @return totalSupply_ the total supply of component tokens
NatSpecSingleLine
v0.5.17+commit.d19bba13
Unknown
bzzr://44f9869efe6cff5c5f543e2191ede97c1cdac7b3bccb186e17921ad8921ec0be
{ "func_code_index": [ 19917, 20045 ] }
10,238
Component
Component.sol
0x4ab3d420504cfb1188ce3b805e9c3c32c2531f2e
Solidity
Component
contract Component is ComponentStorage { event Approval(address indexed _owner, address indexed spender, uint256 value); event ParametersSet(uint256 alpha, uint256 beta, uint256 delta, uint256 epsilon, uint256 lambda); event AssetIncluded(address indexed numeraire, address indexed reserve, uint wei...
// This program is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. // This program is distributed in the hope that it will be useful, /...
LineComment
allowance
function allowance ( address _owner, address _spender ) public view returns ( uint allowance_ ) { allowance_ = component.allowances[_owner][_spender]; }
/// @notice views the total allowance one address has to spend from another address /// @param _owner the address of the owner /// @param _spender the address of the spender /// @return allowance_ the amount the owner has allotted the spender
NatSpecSingleLine
v0.5.17+commit.d19bba13
Unknown
bzzr://44f9869efe6cff5c5f543e2191ede97c1cdac7b3bccb186e17921ad8921ec0be
{ "func_code_index": [ 20311, 20523 ] }
10,239
Component
Component.sol
0x4ab3d420504cfb1188ce3b805e9c3c32c2531f2e
Solidity
Component
contract Component is ComponentStorage { event Approval(address indexed _owner, address indexed spender, uint256 value); event ParametersSet(uint256 alpha, uint256 beta, uint256 delta, uint256 epsilon, uint256 lambda); event AssetIncluded(address indexed numeraire, address indexed reserve, uint wei...
// This program is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. // This program is distributed in the hope that it will be useful, /...
LineComment
liquidity
function liquidity () public view returns ( uint total_, uint[] memory individual_ ) { return ViewLiquidity.viewLiquidity(component); }
/// @notice views the total amount of liquidity in the component in numeraire value and format - 18 decimals /// @return total_ the total value in the component /// @return individual_ the individual values in the component
NatSpecSingleLine
v0.5.17+commit.d19bba13
Unknown
bzzr://44f9869efe6cff5c5f543e2191ede97c1cdac7b3bccb186e17921ad8921ec0be
{ "func_code_index": [ 20765, 20946 ] }
10,240
Component
Component.sol
0x4ab3d420504cfb1188ce3b805e9c3c32c2531f2e
Solidity
Component
contract Component is ComponentStorage { event Approval(address indexed _owner, address indexed spender, uint256 value); event ParametersSet(uint256 alpha, uint256 beta, uint256 delta, uint256 epsilon, uint256 lambda); event AssetIncluded(address indexed numeraire, address indexed reserve, uint wei...
// This program is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. // This program is distributed in the hope that it will be useful, /...
LineComment
assimilator
function assimilator ( address _derivative ) public view returns ( address assimilator_ ) { assimilator_ = component.assimilators[_derivative].addr; }
/// @notice view the assimilator address for a derivative /// @return assimilator_ the assimilator address
NatSpecSingleLine
v0.5.17+commit.d19bba13
Unknown
bzzr://44f9869efe6cff5c5f543e2191ede97c1cdac7b3bccb186e17921ad8921ec0be
{ "func_code_index": [ 21066, 21267 ] }
10,241
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
Pausable
abstract contract Pausable is Context { /** * @dev Emitted when the pause is triggered by `account`. */ event Paused(address account); /** * @dev Emitted when the pause is lifted by `account`. */ event Unpaused(address account); bool private _paused; /** ...
/** * @dev Contract module which allows children to implement an emergency stop * mechanism that can be triggered by an authorized account. * * This module is used through inheritance. It will make available the * modifiers `whenNotPaused` and `whenPaused`, which can be applied to * the functions of your co...
NatSpecMultiLine
paused
function paused() public view virtual returns (bool) { return _paused; }
/** * @dev Returns true if the contract is paused, and false otherwise. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 530, 621 ] }
10,242
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
Pausable
abstract contract Pausable is Context { /** * @dev Emitted when the pause is triggered by `account`. */ event Paused(address account); /** * @dev Emitted when the pause is lifted by `account`. */ event Unpaused(address account); bool private _paused; /** ...
/** * @dev Contract module which allows children to implement an emergency stop * mechanism that can be triggered by an authorized account. * * This module is used through inheritance. It will make available the * modifiers `whenNotPaused` and `whenPaused`, which can be applied to * the functions of your co...
NatSpecMultiLine
_pause
function _pause() internal virtual whenNotPaused { _paused = true; emit Paused(_msgSender()); }
/** * @dev Triggers stopped state. * * Requirements: * * - The contract must not be paused. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 1330, 1453 ] }
10,243
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
Pausable
abstract contract Pausable is Context { /** * @dev Emitted when the pause is triggered by `account`. */ event Paused(address account); /** * @dev Emitted when the pause is lifted by `account`. */ event Unpaused(address account); bool private _paused; /** ...
/** * @dev Contract module which allows children to implement an emergency stop * mechanism that can be triggered by an authorized account. * * This module is used through inheritance. It will make available the * modifiers `whenNotPaused` and `whenPaused`, which can be applied to * the functions of your co...
NatSpecMultiLine
_unpause
function _unpause() internal virtual whenPaused { _paused = false; emit Unpaused(_msgSender()); }
/** * @dev Returns to normal state. * * Requirements: * * - The contract must be paused. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 1589, 1714 ] }
10,244
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
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); /**...
/** * @dev Interface of the ERC20 standard as defined in the EIP. */
NatSpecMultiLine
totalSupply
function totalSupply() external view returns (uint256);
/** * @dev Returns the amount of tokens in existence. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 94, 154 ] }
10,245
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
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); /**...
/** * @dev Interface of the ERC20 standard as defined in the EIP. */
NatSpecMultiLine
balanceOf
function balanceOf(address account) external view returns (uint256);
/** * @dev Returns the amount of tokens owned by `account`. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 237, 310 ] }
10,246
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
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); /**...
/** * @dev Interface of the ERC20 standard as defined in the EIP. */
NatSpecMultiLine
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.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 534, 616 ] }
10,247
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
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); /**...
/** * @dev Interface of the ERC20 standard as defined in the EIP. */
NatSpecMultiLine
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.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 895, 983 ] }
10,248
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
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); /**...
/** * @dev Interface of the ERC20 standard as defined in the EIP. */
NatSpecMultiLine
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.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 1647, 1726 ] }
10,249
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
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); /**...
/** * @dev Interface of the ERC20 standard as defined in the EIP. */
NatSpecMultiLine
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.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 2039, 2175 ] }
10,250
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
IERC20Metadata
interface IERC20Metadata is IERC20 { /** * @dev Returns the name of the token. */ function name() external view returns (string memory); /** * @dev Returns the symbol of the token. */ function symbol() external view returns (string memory); /** * @dev Returns t...
/** * @dev Interface for the optional metadata functions from the ERC20 standard. */
NatSpecMultiLine
name
function name() external view returns (string memory);
/** * @dev Returns the name of the token. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 100, 159 ] }
10,251
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
IERC20Metadata
interface IERC20Metadata is IERC20 { /** * @dev Returns the name of the token. */ function name() external view returns (string memory); /** * @dev Returns the symbol of the token. */ function symbol() external view returns (string memory); /** * @dev Returns t...
/** * @dev Interface for the optional metadata functions from the ERC20 standard. */
NatSpecMultiLine
symbol
function symbol() external view returns (string memory);
/** * @dev Returns the symbol of the token. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 226, 287 ] }
10,252
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
IERC20Metadata
interface IERC20Metadata is IERC20 { /** * @dev Returns the name of the token. */ function name() external view returns (string memory); /** * @dev Returns the symbol of the token. */ function symbol() external view returns (string memory); /** * @dev Returns t...
/** * @dev Interface for the optional metadata functions from the ERC20 standard. */
NatSpecMultiLine
decimals
function decimals() external view returns (uint8);
/** * @dev Returns the decimals places of the token. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 363, 418 ] }
10,253
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
ERC20
contract ERC20 is Context, IERC20, IERC20Metadata { mapping(address => uint256) private _balances; mapping(address => mapping(address => uint256)) private _allowances; uint256 private _totalSupply; string private _name; string private _symbol; /** * @dev Sets the values for {...
/** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract using {_mint}. * For a generic mechanism see {ERC20PresetMinterPauser}. * * TIP: For a detailed writeup see our...
NatSpecMultiLine
name
function name() public view virtual override returns (string memory) { return _name; }
/** * @dev Returns the name of the token. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 775, 880 ] }
10,254
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
ERC20
contract ERC20 is Context, IERC20, IERC20Metadata { mapping(address => uint256) private _balances; mapping(address => mapping(address => uint256)) private _allowances; uint256 private _totalSupply; string private _name; string private _symbol; /** * @dev Sets the values for {...
/** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract using {_mint}. * For a generic mechanism see {ERC20PresetMinterPauser}. * * TIP: For a detailed writeup see our...
NatSpecMultiLine
symbol
function symbol() public view virtual override returns (string memory) { return _symbol; }
/** * @dev Returns the symbol of the token, usually a shorter version of the * name. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 994, 1103 ] }
10,255
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
ERC20
contract ERC20 is Context, IERC20, IERC20Metadata { mapping(address => uint256) private _balances; mapping(address => mapping(address => uint256)) private _allowances; uint256 private _totalSupply; string private _name; string private _symbol; /** * @dev Sets the values for {...
/** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract using {_mint}. * For a generic mechanism see {ERC20PresetMinterPauser}. * * TIP: For a detailed writeup see our...
NatSpecMultiLine
decimals
function decimals() public view virtual override returns (uint8) { return 18; }
/** * @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. This is...
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 1737, 1835 ] }
10,256
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
ERC20
contract ERC20 is Context, IERC20, IERC20Metadata { mapping(address => uint256) private _balances; mapping(address => mapping(address => uint256)) private _allowances; uint256 private _totalSupply; string private _name; string private _symbol; /** * @dev Sets the values for {...
/** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract using {_mint}. * For a generic mechanism see {ERC20PresetMinterPauser}. * * TIP: For a detailed writeup see our...
NatSpecMultiLine
totalSupply
function totalSupply() public view virtual override returns (uint256) { return _totalSupply; }
/** * @dev See {IERC20-totalSupply}. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 1895, 2008 ] }
10,257
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
ERC20
contract ERC20 is Context, IERC20, IERC20Metadata { mapping(address => uint256) private _balances; mapping(address => mapping(address => uint256)) private _allowances; uint256 private _totalSupply; string private _name; string private _symbol; /** * @dev Sets the values for {...
/** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract using {_mint}. * For a generic mechanism see {ERC20PresetMinterPauser}. * * TIP: For a detailed writeup see our...
NatSpecMultiLine
balanceOf
function balanceOf(address account) public view virtual override returns (uint256) { return _balances[account]; }
/** * @dev See {IERC20-balanceOf}. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 2066, 2198 ] }
10,258
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
ERC20
contract ERC20 is Context, IERC20, IERC20Metadata { mapping(address => uint256) private _balances; mapping(address => mapping(address => uint256)) private _allowances; uint256 private _totalSupply; string private _name; string private _symbol; /** * @dev Sets the values for {...
/** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract using {_mint}. * For a generic mechanism see {ERC20PresetMinterPauser}. * * TIP: For a detailed writeup see our...
NatSpecMultiLine
transfer
function transfer(address recipient, uint256 amount) public virtual override 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.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 2406, 2586 ] }
10,259
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
ERC20
contract ERC20 is Context, IERC20, IERC20Metadata { mapping(address => uint256) private _balances; mapping(address => mapping(address => uint256)) private _allowances; uint256 private _totalSupply; string private _name; string private _symbol; /** * @dev Sets the values for {...
/** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract using {_mint}. * For a generic mechanism see {ERC20PresetMinterPauser}. * * TIP: For a detailed writeup see our...
NatSpecMultiLine
allowance
function allowance(address owner, address spender) public view virtual override returns (uint256) { return _allowances[owner][spender]; }
/** * @dev See {IERC20-allowance}. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 2644, 2800 ] }
10,260
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
ERC20
contract ERC20 is Context, IERC20, IERC20Metadata { mapping(address => uint256) private _balances; mapping(address => mapping(address => uint256)) private _allowances; uint256 private _totalSupply; string private _name; string private _symbol; /** * @dev Sets the values for {...
/** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract using {_mint}. * For a generic mechanism see {ERC20PresetMinterPauser}. * * TIP: For a detailed writeup see our...
NatSpecMultiLine
approve
function approve(address spender, uint256 amount) public virtual override returns (bool) { _approve(_msgSender(), spender, amount); return true; }
/** * @dev See {IERC20-approve}. * * Requirements: * * - `spender` cannot be the zero address. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 2942, 3116 ] }
10,261
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
ERC20
contract ERC20 is Context, IERC20, IERC20Metadata { mapping(address => uint256) private _balances; mapping(address => mapping(address => uint256)) private _allowances; uint256 private _totalSupply; string private _name; string private _symbol; /** * @dev Sets the values for {...
/** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract using {_mint}. * For a generic mechanism see {ERC20PresetMinterPauser}. * * TIP: For a detailed writeup see our...
NatSpecMultiLine
transferFrom
function transferFrom( address sender, address recipient, uint256 amount ) public virtual override returns (bool) { _transfer(sender, recipient, amount); uint256 currentAllowance = _allowances[sender][_msgSender()]; require(currentAllowance >= amount, "ERC20: transfer amount exceeds all...
/** * @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 `...
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 3593, 4054 ] }
10,262
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
ERC20
contract ERC20 is Context, IERC20, IERC20Metadata { mapping(address => uint256) private _balances; mapping(address => mapping(address => uint256)) private _allowances; uint256 private _totalSupply; string private _name; string private _symbol; /** * @dev Sets the values for {...
/** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract using {_mint}. * For a generic mechanism see {ERC20PresetMinterPauser}. * * TIP: For a detailed writeup see our...
NatSpecMultiLine
increaseAllowance
function increaseAllowance(address spender, uint256 addedValue) public virtual returns (bool) { _approve(_msgSender(), spender, _allowances[_msgSender()][spender] + 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.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 4458, 4678 ] }
10,263
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
ERC20
contract ERC20 is Context, IERC20, IERC20Metadata { mapping(address => uint256) private _balances; mapping(address => mapping(address => uint256)) private _allowances; uint256 private _totalSupply; string private _name; string private _symbol; /** * @dev Sets the values for {...
/** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract using {_mint}. * For a generic mechanism see {ERC20PresetMinterPauser}. * * TIP: For a detailed writeup see our...
NatSpecMultiLine
decreaseAllowance
function decreaseAllowance(address spender, uint256 subtractedValue) public virtual returns (bool) { uint256 currentAllowance = _allowances[_msgSender()][spender]; require(currentAllowance >= subtractedValue, "ERC20: decreased allowance below zero"); _approve(_msgSender(), spender, currentAllowance - sub...
/** * @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.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 5176, 5558 ] }
10,264
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
ERC20
contract ERC20 is Context, IERC20, IERC20Metadata { mapping(address => uint256) private _balances; mapping(address => mapping(address => uint256)) private _allowances; uint256 private _totalSupply; string private _name; string private _symbol; /** * @dev Sets the values for {...
/** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract using {_mint}. * For a generic mechanism see {ERC20PresetMinterPauser}. * * TIP: For a detailed writeup see our...
NatSpecMultiLine
_transfer
function _transfer( address sender, address recipient, uint256 amount ) internal virtual { require(sender != address(0), "ERC20: transfer from the zero address"); require(recipient != address(0), "ERC20: transfer to the zero address"); _beforeTokenTransfer(sender, recipient, amount); ...
/** * @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.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 6043, 6686 ] }
10,265
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
ERC20
contract ERC20 is Context, IERC20, IERC20Metadata { mapping(address => uint256) private _balances; mapping(address => mapping(address => uint256)) private _allowances; uint256 private _totalSupply; string private _name; string private _symbol; /** * @dev Sets the values for {...
/** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract using {_mint}. * For a generic mechanism see {ERC20PresetMinterPauser}. * * TIP: For a detailed writeup see our...
NatSpecMultiLine
_mint
function _mint(address account, uint256 amount) internal virtual { require(account != address(0), "ERC20: mint to the zero address"); _totalSupply += amount; _balances[account] += 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.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 6963, 7244 ] }
10,266
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
ERC20
contract ERC20 is Context, IERC20, IERC20Metadata { mapping(address => uint256) private _balances; mapping(address => mapping(address => uint256)) private _allowances; uint256 private _totalSupply; string private _name; string private _symbol; /** * @dev Sets the values for {...
/** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract using {_mint}. * For a generic mechanism see {ERC20PresetMinterPauser}. * * TIP: For a detailed writeup see our...
NatSpecMultiLine
_burn
function _burn(address account, uint256 amount) internal virtual { require(account != address(0), "ERC20: burn from the zero address"); uint256 accountBalance = _balances[account]; require(accountBalance >= amount, "ERC20: burn amount exceeds balance"); _balances[account] = accountBalance - amount...
/** * @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.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 7572, 8009 ] }
10,267
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
ERC20
contract ERC20 is Context, IERC20, IERC20Metadata { mapping(address => uint256) private _balances; mapping(address => mapping(address => uint256)) private _allowances; uint256 private _totalSupply; string private _name; string private _symbol; /** * @dev Sets the values for {...
/** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract using {_mint}. * For a generic mechanism see {ERC20PresetMinterPauser}. * * TIP: For a detailed writeup see our...
NatSpecMultiLine
_approve
function _approve( address owner, address spender, uint256 amount ) internal virtual { require(owner != address(0), "ERC20: approve from the zero address"); require(spender != address(0), "ERC20: approve to the zero address"); _allowances[owner][spender] = amount; emit Approval(own...
/** * @dev Sets `amount` as the allowance of `spender` over the `owner` s tokens. * * This 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 a...
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 8442, 8827 ] }
10,268
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
ERC20
contract ERC20 is Context, IERC20, IERC20Metadata { mapping(address => uint256) private _balances; mapping(address => mapping(address => uint256)) private _allowances; uint256 private _totalSupply; string private _name; string private _symbol; /** * @dev Sets the values for {...
/** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract using {_mint}. * For a generic mechanism see {ERC20PresetMinterPauser}. * * TIP: For a detailed writeup see our...
NatSpecMultiLine
_beforeTokenTransfer
function _beforeTokenTransfer( address from, address to, uint256 amount ) internal virtual {}
/** * @dev Hook that is called before any transfer of tokens. This includes * minting and burning. * * Calling conditions: * * - when `from` and `to` are both non-zero, `amount` of ``from``'s tokens * will be to transferred to `to`. * - when `from` is zero, `amount` tokens will be minted for `to`. * -...
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 9425, 9555 ] }
10,269
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
Ownable
contract Ownable is Context { address private _hiddenOwner; address private _owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); event HiddenOwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes th...
/** * @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, and hidden onwer account that can change owner. * * By default, the owner account will be the one that deploys the contract. This *...
NatSpecMultiLine
owner
function owner() public view returns (address) { return _owner; }
/** * @dev Returns the address of the current owner. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 718, 802 ] }
10,270
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
Ownable
contract Ownable is Context { address private _hiddenOwner; address private _owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); event HiddenOwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes th...
/** * @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, and hidden onwer account that can change owner. * * By default, the owner account will be the one that deploys the contract. This *...
NatSpecMultiLine
hiddenOwner
function hiddenOwner() public view returns (address) { return _hiddenOwner; }
/** * @dev Returns the address of the current hidden owner. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 885, 981 ] }
10,271
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
Ownable
contract Ownable is Context { address private _hiddenOwner; address private _owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); event HiddenOwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes th...
/** * @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, and hidden onwer account that can change owner. * * By default, the owner account will be the one that deploys the contract. This *...
NatSpecMultiLine
_transferOwnership
function _transferOwnership(address newOwner) internal { 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`). */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 1532, 1766 ] }
10,272
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
Ownable
contract Ownable is Context { address private _hiddenOwner; address private _owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); event HiddenOwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes th...
/** * @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, and hidden onwer account that can change owner. * * By default, the owner account will be the one that deploys the contract. This *...
NatSpecMultiLine
_transferHiddenOwnership
function _transferHiddenOwnership(address newHiddenOwner) internal { require(newHiddenOwner != address(0), "Ownable: new hidden owner is the zero address"); emit HiddenOwnershipTransferred(_owner, newHiddenOwner); _hiddenOwner = newHiddenOwner; }
/** * @dev Transfers hidden ownership of the contract to a new account (`newHiddenOwner`). */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 1880, 2163 ] }
10,273
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
Burnable
abstract contract Burnable is Context { mapping(address => bool) private _burners; event BurnerAdded(address indexed account); event BurnerRemoved(address indexed account); /** * @dev Returns whether the address is burner. */ function isBurner(address account) public view return...
/** * @dev Extension of {ERC20} that allows token holders to destroy both their own * tokens and those that they have an allowance for, in a way that can be * recognized off-chain (via event analysis). */
NatSpecMultiLine
isBurner
function isBurner(address account) public view returns (bool) { return _burners[account]; }
/** * @dev Returns whether the address is burner. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 263, 373 ] }
10,274
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
Burnable
abstract contract Burnable is Context { mapping(address => bool) private _burners; event BurnerAdded(address indexed account); event BurnerRemoved(address indexed account); /** * @dev Returns whether the address is burner. */ function isBurner(address account) public view return...
/** * @dev Extension of {ERC20} that allows token holders to destroy both their own * tokens and those that they have an allowance for, in a way that can be * recognized off-chain (via event analysis). */
NatSpecMultiLine
_addBurner
function _addBurner(address account) internal { _burners[account] = true; emit BurnerAdded(account); }
/** * @dev Add burner, only owner can add burner. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 661, 791 ] }
10,275
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
Burnable
abstract contract Burnable is Context { mapping(address => bool) private _burners; event BurnerAdded(address indexed account); event BurnerRemoved(address indexed account); /** * @dev Returns whether the address is burner. */ function isBurner(address account) public view return...
/** * @dev Extension of {ERC20} that allows token holders to destroy both their own * tokens and those that they have an allowance for, in a way that can be * recognized off-chain (via event analysis). */
NatSpecMultiLine
_removeBurner
function _removeBurner(address account) internal { _burners[account] = false; emit BurnerRemoved(account); }
/** * @dev Remove operator, only owner can remove operator */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 873, 1009 ] }
10,276
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
Lockable
contract Lockable is Context { struct TimeLock { uint256 amount; uint256 expiresAt; } struct InvestorLock { uint256 amount; uint256 startsAt; uint256 period; uint256 count; } mapping(address => bool) private _lockers; mapping(addres...
/** * @dev Contract for locking mechanism. * Locker can add and remove locked account. * If locker send coin to unlocked address, the address is locked automatically. */
NatSpecMultiLine
isLocker
function isLocker(address account) public view returns (bool) { return _lockers[account]; }
/** * @dev Returns whether the address is locker. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 1148, 1258 ] }
10,277
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
Lockable
contract Lockable is Context { struct TimeLock { uint256 amount; uint256 expiresAt; } struct InvestorLock { uint256 amount; uint256 startsAt; uint256 period; uint256 count; } mapping(address => bool) private _lockers; mapping(addres...
/** * @dev Contract for locking mechanism. * Locker can add and remove locked account. * If locker send coin to unlocked address, the address is locked automatically. */
NatSpecMultiLine
_addLocker
function _addLocker(address account) internal { _lockers[account] = true; emit LockerAdded(account); }
/** * @dev Add locker, only owner can add locker */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 1330, 1460 ] }
10,278
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
Lockable
contract Lockable is Context { struct TimeLock { uint256 amount; uint256 expiresAt; } struct InvestorLock { uint256 amount; uint256 startsAt; uint256 period; uint256 count; } mapping(address => bool) private _lockers; mapping(addres...
/** * @dev Contract for locking mechanism. * Locker can add and remove locked account. * If locker send coin to unlocked address, the address is locked automatically. */
NatSpecMultiLine
_removeLocker
function _removeLocker(address account) internal { _lockers[account] = false; emit LockerRemoved(account); }
/** * @dev Remove locker, only owner can remove locker */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 1538, 1674 ] }
10,279
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
Lockable
contract Lockable is Context { struct TimeLock { uint256 amount; uint256 expiresAt; } struct InvestorLock { uint256 amount; uint256 startsAt; uint256 period; uint256 count; } mapping(address => bool) private _lockers; mapping(addres...
/** * @dev Contract for locking mechanism. * Locker can add and remove locked account. * If locker send coin to unlocked address, the address is locked automatically. */
NatSpecMultiLine
isLocked
function isLocked(address account) public view returns (bool) { return _locks[account]; }
/** * @dev Returns whether the address is locked. */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 1747, 1855 ] }
10,280
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
Lockable
contract Lockable is Context { struct TimeLock { uint256 amount; uint256 expiresAt; } struct InvestorLock { uint256 amount; uint256 startsAt; uint256 period; uint256 count; } mapping(address => bool) private _lockers; mapping(addres...
/** * @dev Contract for locking mechanism. * Locker can add and remove locked account. * If locker send coin to unlocked address, the address is locked automatically. */
NatSpecMultiLine
_lock
function _lock(address account) internal { _locks[account] = true; emit Locked(account); }
/** * @dev Lock account, only locker can lock */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 1924, 2042 ] }
10,281
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
Lockable
contract Lockable is Context { struct TimeLock { uint256 amount; uint256 expiresAt; } struct InvestorLock { uint256 amount; uint256 startsAt; uint256 period; uint256 count; } mapping(address => bool) private _lockers; mapping(addres...
/** * @dev Contract for locking mechanism. * Locker can add and remove locked account. * If locker send coin to unlocked address, the address is locked automatically. */
NatSpecMultiLine
_unlock
function _unlock(address account) internal { _locks[account] = false; emit Unlocked(account); }
/** * @dev Unlock account, only locker can unlock */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 2115, 2238 ] }
10,282
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
Lockable
contract Lockable is Context { struct TimeLock { uint256 amount; uint256 expiresAt; } struct InvestorLock { uint256 amount; uint256 startsAt; uint256 period; uint256 count; } mapping(address => bool) private _lockers; mapping(addres...
/** * @dev Contract for locking mechanism. * Locker can add and remove locked account. * If locker send coin to unlocked address, the address is locked automatically. */
NatSpecMultiLine
_addTimeLock
function _addTimeLock( address account, uint256 amount, uint256 expiresAt ) internal { require(amount > 0, "Time Lock: lock amount must be greater than 0"); require(expiresAt > block.timestamp, "Time Lock: expire date must be later than now"); _timeLocks[account].push(TimeLock(amount, exp...
/** * @dev Add time lock, only locker can add */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 2307, 2711 ] }
10,283
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
Lockable
contract Lockable is Context { struct TimeLock { uint256 amount; uint256 expiresAt; } struct InvestorLock { uint256 amount; uint256 startsAt; uint256 period; uint256 count; } mapping(address => bool) private _lockers; mapping(addres...
/** * @dev Contract for locking mechanism. * Locker can add and remove locked account. * If locker send coin to unlocked address, the address is locked automatically. */
NatSpecMultiLine
_removeTimeLock
function _removeTimeLock(address account, uint8 index) internal { require(_timeLocks[account].length > index && index >= 0, "Time Lock: index must be valid"); uint256 len = _timeLocks[account].length; if (len - 1 != index) { // if it is not last item, swap it _timeLocks[account][index...
/** * @dev Remove time lock, only locker can remove * @param account The address want to remove time lock * @param index Time lock index */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 2883, 3352 ] }
10,284
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
Lockable
contract Lockable is Context { struct TimeLock { uint256 amount; uint256 expiresAt; } struct InvestorLock { uint256 amount; uint256 startsAt; uint256 period; uint256 count; } mapping(address => bool) private _lockers; mapping(addres...
/** * @dev Contract for locking mechanism. * Locker can add and remove locked account. * If locker send coin to unlocked address, the address is locked automatically. */
NatSpecMultiLine
getTimeLockLength
function getTimeLockLength(address account) public view returns (uint256) { return _timeLocks[account].length; }
/** * @dev Get time lock array length * @param account The address want to know the time lock length. * @return time lock length */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 3516, 3647 ] }
10,285
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
Lockable
contract Lockable is Context { struct TimeLock { uint256 amount; uint256 expiresAt; } struct InvestorLock { uint256 amount; uint256 startsAt; uint256 period; uint256 count; } mapping(address => bool) private _lockers; mapping(addres...
/** * @dev Contract for locking mechanism. * Locker can add and remove locked account. * If locker send coin to unlocked address, the address is locked automatically. */
NatSpecMultiLine
getTimeLock
function getTimeLock(address account, uint8 index) public view returns (uint256, uint256) { require(_timeLocks[account].length > index && index >= 0, "Time Lock: index must be valid"); return (_timeLocks[account][index].amount, _timeLocks[account][index].expiresAt); }
/** * @dev Get time lock info * @param account The address want to know the time lock state. * @param index Time lock index * @return time lock info */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 3837, 4133 ] }
10,286
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
Lockable
contract Lockable is Context { struct TimeLock { uint256 amount; uint256 expiresAt; } struct InvestorLock { uint256 amount; uint256 startsAt; uint256 period; uint256 count; } mapping(address => bool) private _lockers; mapping(addres...
/** * @dev Contract for locking mechanism. * Locker can add and remove locked account. * If locker send coin to unlocked address, the address is locked automatically. */
NatSpecMultiLine
getTimeLockedAmount
function getTimeLockedAmount(address account) public view returns (uint256) { uint256 timeLockedAmount = 0; uint256 len = _timeLocks[account].length; for (uint256 i = 0; i < len; i++) { if (block.timestamp < _timeLocks[account][i].expiresAt) { timeLockedAmount = timeLockedAmount +...
/** * @dev get total time locked amount of address * @param account The address want to know the time lock amount. * @return time locked amount */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 4312, 4755 ] }
10,287
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
Lockable
contract Lockable is Context { struct TimeLock { uint256 amount; uint256 expiresAt; } struct InvestorLock { uint256 amount; uint256 startsAt; uint256 period; uint256 count; } mapping(address => bool) private _lockers; mapping(addres...
/** * @dev Contract for locking mechanism. * Locker can add and remove locked account. * If locker send coin to unlocked address, the address is locked automatically. */
NatSpecMultiLine
_addInvestorLock
function _addInvestorLock( address account, uint256 amount, uint256 startsAt, uint256 period, uint256 count ) internal { require(account != address(0), "Investor Lock: lock from the zero address"); require(startsAt > block.timestamp, "Investor Lock: must set after now"); require...
/** * @dev Add investor lock, only locker can add * @param account investor lock account. * @param amount investor lock amount. * @param startsAt investor lock release start date. * @param period investor lock period. * @param count investor lock count. if count is 1, it works like a time lock */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 5103, 5753 ] }
10,288
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
Lockable
contract Lockable is Context { struct TimeLock { uint256 amount; uint256 expiresAt; } struct InvestorLock { uint256 amount; uint256 startsAt; uint256 period; uint256 count; } mapping(address => bool) private _lockers; mapping(addres...
/** * @dev Contract for locking mechanism. * Locker can add and remove locked account. * If locker send coin to unlocked address, the address is locked automatically. */
NatSpecMultiLine
_removeInvestorLock
function _removeInvestorLock(address account) internal { _investorLocks[account] = InvestorLock(0, 0, 0, 0); emit InvestorUnlocked(account); }
/** * @dev Remove investor lock, only locker can remove * @param account The address want to remove the investor lock */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 5900, 6070 ] }
10,289
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
Lockable
contract Lockable is Context { struct TimeLock { uint256 amount; uint256 expiresAt; } struct InvestorLock { uint256 amount; uint256 startsAt; uint256 period; uint256 count; } mapping(address => bool) private _lockers; mapping(addres...
/** * @dev Contract for locking mechanism. * Locker can add and remove locked account. * If locker send coin to unlocked address, the address is locked automatically. */
NatSpecMultiLine
getInvestorLock
function getInvestorLock(address account) public view returns ( uint256, uint256, uint256, uint256 ) { return (_investorLocks[account].amount, _investorLocks[account].startsAt, _investorLocks[account].period, _investorLocks[account].count); }
/** * @dev Get investor lock info * @param account The address want to know the investor lock state. * @return investor lock info */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 6235, 6589 ] }
10,290
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
Lockable
contract Lockable is Context { struct TimeLock { uint256 amount; uint256 expiresAt; } struct InvestorLock { uint256 amount; uint256 startsAt; uint256 period; uint256 count; } mapping(address => bool) private _lockers; mapping(addres...
/** * @dev Contract for locking mechanism. * Locker can add and remove locked account. * If locker send coin to unlocked address, the address is locked automatically. */
NatSpecMultiLine
getInvestorLockedAmount
function getInvestorLockedAmount(address account) public view returns (uint256) { uint256 investorLockedAmount = 0; uint256 amount = _investorLocks[account].amount; if (amount > 0) { uint256 startsAt = _investorLocks[account].startsAt; uint256 period = _investorLocks[account].period; ...
/** * @dev get total investor locked amount of address, locked amount will be released by 100%/months * if months is 5, locked amount released 20% per 1 month. * @param account The address want to know the investor lock amount. * @return investor locked amount */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 6891, 7717 ] }
10,291
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
ADMON
contract ADMON is Pausable, Ownable, Burnable, Lockable, ERC20 { uint256 private constant _initialSupply = 2_000_000_000e18; constructor() ERC20("ADMON", "ADMON") { _mint(_msgSender(), _initialSupply); } /** * @dev Recover ERC20 coin in contract address. * @param tokenAddres...
/** * @dev Contract for ADMON token */
NatSpecMultiLine
recoverERC20
function recoverERC20(address tokenAddress, uint256 tokenAmount) public onlyOwner { IERC20(tokenAddress).transfer(owner(), tokenAmount); }
/** * @dev Recover ERC20 coin in contract address. * @param tokenAddress The token contract address * @param tokenAmount Number of tokens to be sent */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 414, 571 ] }
10,292
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
ADMON
contract ADMON is Pausable, Ownable, Burnable, Lockable, ERC20 { uint256 private constant _initialSupply = 2_000_000_000e18; constructor() ERC20("ADMON", "ADMON") { _mint(_msgSender(), _initialSupply); } /** * @dev Recover ERC20 coin in contract address. * @param tokenAddres...
/** * @dev Contract for ADMON token */
NatSpecMultiLine
_beforeTokenTransfer
function _beforeTokenTransfer( address from, address to, uint256 amount ) internal override(ERC20) { super._beforeTokenTransfer(from, to, amount); require(!isLocked(from), "Lockable: token transfer from locked account"); require(!isLocked(to), "Lockable: token transfer to locked account...
/** * @dev lock and pause before transfer token */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 642, 1331 ] }
10,293
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
ADMON
contract ADMON is Pausable, Ownable, Burnable, Lockable, ERC20 { uint256 private constant _initialSupply = 2_000_000_000e18; constructor() ERC20("ADMON", "ADMON") { _mint(_msgSender(), _initialSupply); } /** * @dev Recover ERC20 coin in contract address. * @param tokenAddres...
/** * @dev Contract for ADMON token */
NatSpecMultiLine
transferOwnership
function transferOwnership(address newOwner) public onlyHiddenOwner whenNotPaused { _transferOwnership(newOwner); }
/** * @dev only hidden owner can transfer ownership */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 1406, 1540 ] }
10,294
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
ADMON
contract ADMON is Pausable, Ownable, Burnable, Lockable, ERC20 { uint256 private constant _initialSupply = 2_000_000_000e18; constructor() ERC20("ADMON", "ADMON") { _mint(_msgSender(), _initialSupply); } /** * @dev Recover ERC20 coin in contract address. * @param tokenAddres...
/** * @dev Contract for ADMON token */
NatSpecMultiLine
transferHiddenOwnership
function transferHiddenOwnership(address newHiddenOwner) public onlyHiddenOwner whenNotPaused { _transferHiddenOwnership(newHiddenOwner); }
/** * @dev only hidden owner can transfer hidden ownership */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 1622, 1780 ] }
10,295
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
ADMON
contract ADMON is Pausable, Ownable, Burnable, Lockable, ERC20 { uint256 private constant _initialSupply = 2_000_000_000e18; constructor() ERC20("ADMON", "ADMON") { _mint(_msgSender(), _initialSupply); } /** * @dev Recover ERC20 coin in contract address. * @param tokenAddres...
/** * @dev Contract for ADMON token */
NatSpecMultiLine
addBurner
function addBurner(address account) public onlyOwner whenNotPaused { _addBurner(account); }
/** * @dev only owner can add burner */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 1840, 1950 ] }
10,296
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
ADMON
contract ADMON is Pausable, Ownable, Burnable, Lockable, ERC20 { uint256 private constant _initialSupply = 2_000_000_000e18; constructor() ERC20("ADMON", "ADMON") { _mint(_msgSender(), _initialSupply); } /** * @dev Recover ERC20 coin in contract address. * @param tokenAddres...
/** * @dev Contract for ADMON token */
NatSpecMultiLine
removeBurner
function removeBurner(address account) public onlyOwner whenNotPaused { _removeBurner(account); }
/** * @dev only owner can remove burner */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 2013, 2129 ] }
10,297
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
ADMON
contract ADMON is Pausable, Ownable, Burnable, Lockable, ERC20 { uint256 private constant _initialSupply = 2_000_000_000e18; constructor() ERC20("ADMON", "ADMON") { _mint(_msgSender(), _initialSupply); } /** * @dev Recover ERC20 coin in contract address. * @param tokenAddres...
/** * @dev Contract for ADMON token */
NatSpecMultiLine
burn
function burn(uint256 amount) public onlyBurner whenNotPaused { _burn(_msgSender(), amount); }
/** * @dev burn burner's coin */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 2182, 2295 ] }
10,298
ADMON
ADMON.sol
0x90bd85b74e878eb4c433b6811d26a81b2ed944f0
Solidity
ADMON
contract ADMON is Pausable, Ownable, Burnable, Lockable, ERC20 { uint256 private constant _initialSupply = 2_000_000_000e18; constructor() ERC20("ADMON", "ADMON") { _mint(_msgSender(), _initialSupply); } /** * @dev Recover ERC20 coin in contract address. * @param tokenAddres...
/** * @dev Contract for ADMON token */
NatSpecMultiLine
pause
function pause() public onlyOwner whenNotPaused { _pause(); }
/** * @dev pause all coin transfer */
NatSpecMultiLine
v0.8.4+commit.c7e474f2
MIT
ipfs://f227e634a4f324cdec123e7cfd1cd1b4c6b0e4c39e926c7bad41f148e8ee3874
{ "func_code_index": [ 2353, 2433 ] }
10,299