Contract 0xE4f21842E5D7faD1FB360B7623946376db94fEF3

 
Txn Hash Method
Block
From
To
Value [Txn Fee]
0x9bd2a4234a22c622401131ad7ae15bb013d74fa0b93786cbbe60265ba7f17142Exit Pool196523612021-09-29 18:27:2568 days 3 hrs ago0xe72bcbe26d5c9844d55bda1fb4247277fbb55448 IN  0xe4f21842e5d7fad1fb360b7623946376db94fef30 MATIC0.00071343
0x0124b4cf8062490eb5905b73788ab78f7cdf31c6981f8e8a6935df90fab1ff310x60806040184968802021-08-28 19:41:33100 days 2 hrs ago0xab0c9bc6bcbaad9391c530f33f9294dec38ae189 IN  Contract Creation0 MATIC0.00536615271
[ Download CSV Export 
Parent Txn Hash Block From To Value
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
BasketFacet

Compiler Version
v0.7.1+commit.f4a555be

Optimization Enabled:
No with 200 runs

Other Settings:
default evmVersion, None license

Contract Source Code (Solidity)

/**
 *Submitted for verification at polygonscan.com on 2021-08-28
*/

// File: Diamond/LibBasketStorage.sol


pragma solidity ^0.7.1;

library LibBasketStorage {
  bytes32 constant BASKET_STORAGE_POSITION = keccak256(
    "diamond.standard.basket.storage"
  );

  struct BasketStorage {
    uint256 lockBlock;
    uint256 maxCap;
    IERC20[] tokens;
    mapping(address => bool) inPool;
    uint256 entryFee;
    uint256 entryFeeBeneficiaryShare; // amount of entry fee that goes to feeBeneficiary
    uint256 exitFee;
    uint256 exitFeeBeneficiaryShare; // amount of exit fee that goes to the pool itself
    uint256 annualizedFee;
    uint256 lastAnnualizedFeeClaimed;
    address feeBeneficiary;
  }

  function basketStorage() internal pure returns (BasketStorage storage bs) {
    bytes32 position = BASKET_STORAGE_POSITION;
    assembly {
      bs.slot := position
    }
  }
}
// File: Interfaces/IDiamondCut.sol


pragma solidity ^0.7.1;


/******************************************************************************\
* Author: Nick Mudge <[email protected]> (https://twitter.com/mudgen)
/******************************************************************************/

interface IDiamondCut {
    enum FacetCutAction {Add, Replace, Remove}

    struct FacetCut {
        address facetAddress;
        FacetCutAction action;
        bytes4[] functionSelectors;
    }

    /// @notice Add/replace/remove any number of functions and optionally execute
    ///         a function with delegatecall
    /// @param _diamondCut Contains the facet addresses and function selectors
    /// @param _init The address of the contract or facet to execute _calldata
    /// @param _calldata A function call, including function selector and arguments
    ///                  _calldata is executed with delegatecall on _init
    function diamondCut(
        FacetCut[] calldata _diamondCut,
        address _init,
        bytes calldata _calldata
    ) external;

    event DiamondCut(FacetCut[] _diamondCut, address _init, bytes _calldata);
}
// File: Diamond/LibDiamond.sol


pragma solidity ^0.7.1;

/******************************************************************************\
* Author: Nick Mudge
*
* Implementation of Diamond facet.
* This is gas optimized by reducing storage reads and storage writes.
* This code is as complex as it is to reduce gas costs.
/******************************************************************************/


library LibDiamond {
        bytes32 constant DIAMOND_STORAGE_POSITION = keccak256("diamond.standard.diamond.storage");

    struct DiamondStorage {
        // maps function selectors to the facets that execute the functions.
        // and maps the selectors to their position in the selectorSlots array.        
        // func selector => address facet, selector position
        mapping(bytes4 => bytes32) facets;
        // array of slots of function selectors.
        // each slot holds 8 function selectors.
        mapping(uint256 => bytes32) selectorSlots;
        // The number of function selectors in selectorSlots
        uint16 selectorCount;
        // owner of the contract
        // Used to query if a contract implements an interface.
        // Used to implement ERC-165.
        mapping(bytes4 => bool) supportedInterfaces;
        // owner of the contract
        address contractOwner;
    }

    function diamondStorage() internal pure returns (DiamondStorage storage ds) {
        bytes32 position = DIAMOND_STORAGE_POSITION;
        assembly {
            ds.slot := position
        }
    }
   
   event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);

   function setContractOwner(address _newOwner) internal {
        DiamondStorage storage ds = diamondStorage();
        address previousOwner = ds.contractOwner;
        ds.contractOwner = _newOwner;
        emit OwnershipTransferred(previousOwner, _newOwner);
    }

    function contractOwner() internal view returns (address contractOwner_) {
        contractOwner_ = diamondStorage().contractOwner;
    }

    function enforceIsContractOwner() view internal {
        require(msg.sender == diamondStorage().contractOwner, "LibDiamond: Must be contract owner");
    }

    modifier onlyOwner {
        require(msg.sender == diamondStorage().contractOwner, "LibDiamond: Must be contract owner");
        _;
    }

    event DiamondCut(IDiamondCut.FacetCut[] _diamondCut, address _init, bytes _calldata);

    bytes32 constant CLEAR_ADDRESS_MASK = bytes32(uint256(0xffffffffffffffffffffffff));
    bytes32 constant CLEAR_SELECTOR_MASK = bytes32(uint256(0xffffffff << 224));

    // Internal function version of diamondCut
    // This code is almost the same as the external diamondCut,
    // except it is using 'Facet[] memory _diamondCut' instead of
    // 'Facet[] calldata _diamondCut'.
    // The code is duplicated to prevent copying calldata to memory which
    // causes an error for a two dimensional array.
    function diamondCut(
        IDiamondCut.FacetCut[] memory _diamondCut,
        address _init,
        bytes memory _calldata
    ) internal {
        DiamondStorage storage ds = diamondStorage();
        uint256 originalSelectorCount = ds.selectorCount;
        uint256 selectorCount = originalSelectorCount;
        bytes32 selectorSlot;
        // Check if last selector slot is not full
        if (selectorCount % 8 > 0) {
            // get last selectorSlot
            selectorSlot = ds.selectorSlots[selectorCount / 8];
        }
        // loop through diamond cut
        for (uint256 facetIndex; facetIndex < _diamondCut.length; facetIndex++) {
            (selectorCount, selectorSlot) = addReplaceRemoveFacetSelectors(
                selectorCount,
                selectorSlot,
                _diamondCut[facetIndex].facetAddress,
                _diamondCut[facetIndex].action,
                _diamondCut[facetIndex].functionSelectors
            );
        }
        if (selectorCount != originalSelectorCount) {
            ds.selectorCount = uint16(selectorCount);
        }
        // If last selector slot is not full
        if (selectorCount % 8 > 0) {
            ds.selectorSlots[selectorCount / 8] = selectorSlot;
        }
        emit DiamondCut(_diamondCut, _init, _calldata);
        initializeDiamondCut(_init, _calldata);
    }

    function addReplaceRemoveFacetSelectors(
        uint256 _selectorCount,
        bytes32 _selectorSlot,
        address _newFacetAddress,
        IDiamondCut.FacetCutAction _action,
        bytes4[] memory _selectors
    ) internal returns (uint256, bytes32) {
        DiamondStorage storage ds = diamondStorage();
        require(_selectors.length > 0, "LibDiamondCut: No selectors in facet to cut");        
        if (_action == IDiamondCut.FacetCutAction.Add) {
            require(_newFacetAddress != address(0), "LibDiamondCut: Add facet can't be address(0)");
            enforceHasContractCode(_newFacetAddress, "LibDiamondCut: Add facet has no code");
            for (uint256 selectorIndex; selectorIndex < _selectors.length; selectorIndex++) {
                bytes4 selector = _selectors[selectorIndex];
                bytes32 oldFacet = ds.facets[selector];                
                require(address(bytes20(oldFacet)) == address(0), "LibDiamondCut: Can't add function that already exists");
                // add facet for selector                                
                ds.facets[selector] = bytes20(_newFacetAddress) | bytes32(_selectorCount);                
                uint256 selectorInSlotPosition = (_selectorCount % 8) * 32;
                // clear selector position in slot and add selector
                _selectorSlot =
                    (_selectorSlot & ~(CLEAR_SELECTOR_MASK >> selectorInSlotPosition)) |
                    (bytes32(selector) >> selectorInSlotPosition);
                // if slot is full then write it to storage
                if (selectorInSlotPosition == 224) {
                    ds.selectorSlots[_selectorCount / 8] = _selectorSlot;
                    _selectorSlot = 0;
                }
                _selectorCount++;
            }
        } else if(_action == IDiamondCut.FacetCutAction.Replace) {
            require(_newFacetAddress != address(0), "LibDiamondCut: Replace facet can't be address(0)");
            enforceHasContractCode(_newFacetAddress, "LibDiamondCut: Replace facet has no code");
            for (uint256 selectorIndex; selectorIndex < _selectors.length; selectorIndex++) {
                bytes4 selector = _selectors[selectorIndex];
                bytes32 oldFacet = ds.facets[selector];  
                address oldFacetAddress = address(bytes20(oldFacet));
                // only useful if immutable functions exist
                require(oldFacetAddress != address(this), "LibDiamondCut: Can't replace immutable function");
                require(oldFacetAddress != _newFacetAddress, "LibDiamondCut: Can't replace function with same function");
                require(oldFacetAddress != address(0), "LibDiamondCut: Can't replace function that doesn't exist");
                // replace old facet address
                ds.facets[selector] = (oldFacet & CLEAR_ADDRESS_MASK) | bytes20(_newFacetAddress);
            }
        } else if(_action == IDiamondCut.FacetCutAction.Remove) {
            require(_newFacetAddress == address(0), "LibDiamondCut: Remove facet address must be address(0)");
            uint256 selectorSlotCount = _selectorCount / 8;
            uint256 selectorInSlotIndex = (_selectorCount % 8) - 1;
            for (uint256 selectorIndex; selectorIndex < _selectors.length; selectorIndex++) {
                if (_selectorSlot == 0) {
                    // get last selectorSlot
                    selectorSlotCount--;
                    _selectorSlot = ds.selectorSlots[selectorSlotCount];
                    selectorInSlotIndex = 7;
                }
                bytes4 lastSelector;
                uint256 oldSelectorsSlotCount;
                uint256 oldSelectorInSlotPosition;
                // adding a block here prevents stack too deep error
                {
                    bytes4 selector = _selectors[selectorIndex];
                    bytes32 oldFacet = ds.facets[selector];
                    require(address(bytes20(oldFacet)) != address(0), "LibDiamondCut: Can't remove function that doesn't exist");
                    // only useful if immutable functions exist
                    require(address(bytes20(oldFacet)) != address(this), "LibDiamondCut: Can't remove immutable function");
                    // replace selector with last selector in ds.facets
                    // gets the last selector
                    lastSelector = bytes4(_selectorSlot << (selectorInSlotIndex * 32));
                    if (lastSelector != selector) {
                        // update last selector slot position info
                        ds.facets[lastSelector] = (oldFacet & CLEAR_ADDRESS_MASK) | bytes20(ds.facets[lastSelector]);
                    }
                    delete ds.facets[selector];
                    uint256 oldSelectorCount = uint16(uint256(oldFacet));
                    oldSelectorsSlotCount = oldSelectorCount / 8;
                    oldSelectorInSlotPosition = (oldSelectorCount % 8) * 32;
                }
                if (oldSelectorsSlotCount != selectorSlotCount) {
                    bytes32 oldSelectorSlot = ds.selectorSlots[oldSelectorsSlotCount];
                    // clears the selector we are deleting and puts the last selector in its place.
                    oldSelectorSlot =
                        (oldSelectorSlot & ~(CLEAR_SELECTOR_MASK >> oldSelectorInSlotPosition)) |
                        (bytes32(lastSelector) >> oldSelectorInSlotPosition);
                    // update storage with the modified slot
                    ds.selectorSlots[oldSelectorsSlotCount] = oldSelectorSlot;
                } else {
                    // clears the selector we are deleting and puts the last selector in its place.
                    _selectorSlot =
                        (_selectorSlot & ~(CLEAR_SELECTOR_MASK >> oldSelectorInSlotPosition)) |
                        (bytes32(lastSelector) >> oldSelectorInSlotPosition);
                }
                if (selectorInSlotIndex == 0) {
                    delete ds.selectorSlots[selectorSlotCount];
                    _selectorSlot = 0;
                }
                selectorInSlotIndex--;
            }
            _selectorCount = selectorSlotCount * 8 + selectorInSlotIndex + 1;
        } else {
            revert("LibDiamondCut: Incorrect FacetCutAction");
        }       
        return (_selectorCount, _selectorSlot);
    }

    function initializeDiamondCut(address _init, bytes memory _calldata) internal {
        if (_init == address(0)) {
            require(_calldata.length == 0, "LibDiamondCut: _init is address(0) but_calldata is not empty");
        } else {
            require(_calldata.length > 0, "LibDiamondCut: _calldata is empty but _init is not address(0)");
            if (_init != address(this)) {
                enforceHasContractCode(_init, "LibDiamondCut: _init address has no code");
            }
            (bool success, bytes memory error) = _init.delegatecall(_calldata);
            if (!success) {
                if (error.length > 0) {
                    // bubble up the error
                    revert(string(error));
                } else {
                    revert("LibDiamondCut: _init function reverted");
                }
            }
        }
    }

    function enforceHasContractCode(address _contract, string memory _errorMessage) internal view {
        uint256 contractSize;
        assembly {
            contractSize := extcodesize(_contract)
        }
        require(contractSize > 0, _errorMessage);
    }
}
// File: Diamond/CallProtection.sol


pragma solidity ^0.7.1;


contract CallProtection {
    modifier protectedCall() {
        require(
            msg.sender == LibDiamond.diamondStorage().contractOwner ||
            msg.sender == address(this), "NOT_ALLOWED"
        );
        _;
    }
}
// File: Diamond/LibReentryProtectionStorage.sol


pragma solidity ^0.7.1;

library LibReentryProtectionStorage {
  bytes32 constant REENTRY_STORAGE_POSITION = keccak256(
    "diamond.standard.reentry.storage"
  );

  struct RPStorage {
    uint256 lockCounter;
  }

  function rpStorage() internal pure returns (RPStorage storage bs) {
    bytes32 position = REENTRY_STORAGE_POSITION;
    assembly {
      bs.slot := position
    }
  }
}
// File: Diamond/ReentryProtection.sol


pragma solidity ^0.7.1;


contract ReentryProtection {
  modifier noReentry {
    // Use counter to only write to storage once
    LibReentryProtectionStorage.RPStorage storage s = LibReentryProtectionStorage.rpStorage();
    s.lockCounter++;
    uint256 lockValue = s.lockCounter;
    _;
    require(
      lockValue == s.lockCounter,
      "ReentryProtectionFacet.noReentry: reentry detected"
    );
  }
}
// File: Diamond/LibERC20.sol


pragma solidity ^0.7.1;




library LibERC20 {
  using SafeMath for uint256;

  // Need to include events locally because `emit Interface.Event(params)` does not work
  event Transfer(address indexed from, address indexed to, uint256 amount);

  function mint(address _to, uint256 _amount) internal {
    require(_to != address(0), "INVALID_TO_ADDRESS");

    LibERC20Storage.ERC20Storage storage es = LibERC20Storage.erc20Storage();

    es.balances[_to] = es.balances[_to].add(_amount);
    es.totalSupply = es.totalSupply.add(_amount);
    emit Transfer(address(0), _to, _amount);
  }

  function burn(address _from, uint256 _amount) internal {
    LibERC20Storage.ERC20Storage storage es = LibERC20Storage.erc20Storage();

    es.balances[_from] = es.balances[_from].sub(_amount);
    es.totalSupply = es.totalSupply.sub(_amount);
    emit Transfer(_from, address(0), _amount);
  }
}
// File: Diamond/LibERC20Storage.sol


pragma solidity ^0.7.1;

library LibERC20Storage {
  bytes32 constant ERC_20_STORAGE_POSITION = keccak256(
    // Compatible with pie-smart-pools
    "PCToken.storage.location"
  );

  struct ERC20Storage {
    string name;
    string symbol;
    uint256 totalSupply;
    mapping(address => uint256) balances;
    mapping(address => mapping(address => uint256)) allowances;
  }

  function erc20Storage() internal pure returns (ERC20Storage storage es) {
    bytes32 position = ERC_20_STORAGE_POSITION;
    assembly {
      es.slot := position
    }
  }
}
// File: Interfaces/IBasketFacet.sol


pragma solidity ^0.7.1;

interface IBasketFacet {

    event TokenAdded(address indexed _token);
    event TokenRemoved(address indexed _token);
    event EntryFeeSet(uint256 fee);
    event ExitFeeSet(uint256 fee);
    event AnnualizedFeeSet(uint256 fee);
    event FeeBeneficiarySet(address indexed beneficiary);
    event EntryFeeBeneficiaryShareSet(uint256 share);
    event ExitFeeBeneficiaryShareSet(uint256 share);

    event PoolJoined(address indexed who, uint256 amount);
    event PoolExited(address indexed who, uint256 amount);
    event FeeCharged(uint256 amount);
    event LockSet(uint256 lockBlock);
    event CapSet(uint256 cap);

    /** 
        @notice Sets entry fee paid when minting
        @param _fee Amount of fee. 1e18 == 100%, capped at 10%
    */
    function setEntryFee(uint256 _fee) external;

    /**
        @notice Get the entry fee
        @return Current entry fee
    */
    function getEntryFee() external view returns(uint256);

    /**
        @notice Set the exit fee paid when exiting
        @param _fee Amount of fee. 1e18 == 100%, capped at 10%
    */
    function setExitFee(uint256 _fee) external;

    /**
        @notice Get the exit fee
        @return Current exit fee
    */
    function getExitFee() external view returns(uint256);

    /**
        @notice Set the annualized fee. Often referred to as streaming fee
        @param _fee Amount of fee. 1e18 == 100%, capped at 10%
    */
    function setAnnualizedFee(uint256 _fee) external;

    /**
        @notice Get the annualized fee.
        @return Current annualized fee.
    */
    function getAnnualizedFee() external view returns(uint256);

    /**
        @notice Set the address receiving the fees.
    */
    function setFeeBeneficiary(address _beneficiary) external;

    /**
        @notice Get the fee benificiary
        @return The current fee beneficiary
    */
    function getFeeBeneficiary() external view returns(address);

    /**
        @notice Set the fee beneficiaries share of the entry fee
        @notice _share Share of the fee. 1e18 == 100%. Capped at 100% 
    */
    function setEntryFeeBeneficiaryShare(uint256 _share) external;

    /**
        @notice Get the entry fee beneficiary share
        @return Feeshare amount
    */
    function getEntryFeeBeneficiaryShare() external view returns(uint256);

    /**
        @notice Set the fee beneficiaries share of the exit fee
        @notice _share Share of the fee. 1e18 == 100%. Capped at 100% 
    */
    function setExitFeeBeneficiaryShare(uint256 _share) external;

    /**
        @notice Get the exit fee beneficiary share
        @return Feeshare amount
    */
    function getExitFeeBeneficiaryShare() external view returns(uint256);

    /**
        @notice Calculate the oustanding annualized fee
        @return Amount of pool tokens to be minted to charge the annualized fee
    */
    function calcOutStandingAnnualizedFee() external view returns(uint256);

    /**
        @notice Charges the annualized fee
    */
    function chargeOutstandingAnnualizedFee() external;

    /**
        @notice Pulls underlying from caller and mints the pool token
        @param _amount Amount of pool tokens to mint
    */
    function joinPool(uint256 _amount) external;

    /**
        @notice Burns pool tokens from the caller and returns underlying assets
    */
    function exitPool(uint256 _amount) external;

    /**
        @notice Get if the pool is locked or not. (not accepting exit and entry)
        @return Boolean indicating if the pool is locked
    */
    function getLock() external view returns (bool);

    /**
        @notice Get the block until which the pool is locked
        @return The lock block
    */
    function getLockBlock() external view returns (uint256);

    /**
        @notice Set the lock block
        @param _lock Block height of the lock
    */
    function setLock(uint256 _lock) external;

    /**
        @notice Get the maximum of pool tokens that can be minted
        @return Cap
    */
    function getCap() external view returns (uint256);

    /**
        @notice Set the maximum of pool tokens that can be minted
        @param _maxCap Max cap 
    */
    function setCap(uint256 _maxCap) external;

    /**
        @notice Get the amount of tokens owned by the pool
        @param _token Addres of the token
        @return Amount owned by the contract
    */
    function balance(address _token) external view returns (uint256);

    /**
        @notice Get the tokens in the pool
        @return Array of tokens in the pool
    */
    function getTokens() external view returns (address[] memory);

    /**
        @notice Add a token to the pool. Should have at least a balance of 10**6
        @param _token Address of the token to add
    */
    function addToken(address _token) external;

    /**
        @notice Removes a token from the pool
        @param _token Address of the token to remove
    */
    function removeToken(address _token) external;

    /**
        @notice Checks if a token was added to the pool
        @param _token address of the token
        @return If token is in the pool or not
    */
    function getTokenInPool(address _token) external view returns (bool);

    /**
        @notice Calculate the amounts of underlying needed to mint that pool amount.
        @param _amount Amount of pool tokens to mint
        @return tokens Tokens needed
        @return amounts Amounts of underlying needed
    */
    function calcTokensForAmount(uint256 _amount)
        external
        view
        returns (address[] memory tokens, uint256[] memory amounts);

    /**
        @notice Calculate the amounts of underlying to receive when burning that pool amount
        @param _amount Amount of pool tokens to burn
        @return tokens Tokens returned
        @return amounts Amounts of underlying returned
    */
    function calcTokensForAmountExit(uint256 _amount)
        external
        view
        returns (address[] memory tokens, uint256[] memory amounts);
}
// File: OpenZeppelin/Address.sol



pragma solidity ^0.7.0;

/**
 * @dev Collection of functions related to the address type
 */
library Address {
    /**
     * @dev Returns true if `account` is a contract.
     *
     * [IMPORTANT]
     * ====
     * It is unsafe to assume that an address for which this function returns
     * false is an externally-owned account (EOA) and not a contract.
     *
     * Among others, `isContract` will return false for the following
     * types of addresses:
     *
     *  - an externally-owned account
     *  - a contract in construction
     *  - an address where a contract will be created
     *  - an address where a contract lived, but was destroyed
     * ====
     */
    function isContract(address account) internal view returns (bool) {
        // According to EIP-1052, 0x0 is the value returned for not-yet created accounts
        // and 0xc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470 is returned
        // for accounts without code, i.e. `keccak256('')`
        bytes32 codehash;
        bytes32 accountHash = 0xc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470;
        // solhint-disable-next-line no-inline-assembly
        assembly { codehash := extcodehash(account) }
        return (codehash != accountHash && codehash != 0x0);
    }

    /**
     * @dev Replacement for Solidity's `transfer`: sends `amount` wei to
     * `recipient`, forwarding all available gas and reverting on errors.
     *
     * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost
     * of certain opcodes, possibly making contracts go over the 2300 gas limit
     * imposed by `transfer`, making them unable to receive funds via
     * `transfer`. {sendValue} removes this limitation.
     *
     * https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more].
     *
     * IMPORTANT: because control is transferred to `recipient`, care must be
     * taken to not create reentrancy vulnerabilities. Consider using
     * {ReentrancyGuard} or the
     * https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern].
     */
    function sendValue(address payable recipient, uint256 amount) internal {
        require(address(this).balance >= amount, "Address: insufficient balance");

        // solhint-disable-next-line avoid-low-level-calls, avoid-call-value
        (bool success, ) = recipient.call{ value: amount }("");
        require(success, "Address: unable to send value, recipient may have reverted");
    }

    /**
     * @dev Performs a Solidity function call using a low level `call`. A
     * plain`call` is an unsafe replacement for a function call: use this
     * function instead.
     *
     * If `target` reverts with a revert reason, it is bubbled up by this
     * function (like regular Solidity function calls).
     *
     * Returns the raw returned data. To convert to the expected return value,
     * use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`].
     *
     * Requirements:
     *
     * - `target` must be a contract.
     * - calling `target` with `data` must not revert.
     *
     * _Available since v3.1._
     */
    function functionCall(address target, bytes memory data) internal returns (bytes memory) {
      return functionCall(target, data, "Address: low-level call failed");
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with
     * `errorMessage` as a fallback revert reason when `target` reverts.
     *
     * _Available since v3.1._
     */
    function functionCall(address target, bytes memory data, string memory errorMessage) internal returns (bytes memory) {
        return _functionCallWithValue(target, data, 0, errorMessage);
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
     * but also transferring `value` wei to `target`.
     *
     * Requirements:
     *
     * - the calling contract must have an ETH balance of at least `value`.
     * - the called Solidity function must be `payable`.
     *
     * _Available since v3.1._
     */
    function functionCallWithValue(address target, bytes memory data, uint256 value) internal returns (bytes memory) {
        return functionCallWithValue(target, data, value, "Address: low-level call with value failed");
    }

    /**
     * @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but
     * with `errorMessage` as a fallback revert reason when `target` reverts.
     *
     * _Available since v3.1._
     */
    function functionCallWithValue(address target, bytes memory data, uint256 value, string memory errorMessage) internal returns (bytes memory) {
        require(address(this).balance >= value, "Address: insufficient balance for call");
        return _functionCallWithValue(target, data, value, errorMessage);
    }

    function _functionCallWithValue(address target, bytes memory data, uint256 weiValue, string memory errorMessage) private returns (bytes memory) {
        require(isContract(target), "Address: call to non-contract");

        // solhint-disable-next-line avoid-low-level-calls
        (bool success, bytes memory returndata) = target.call{ value: weiValue }(data);
        if (success) {
            return returndata;
        } else {
            // Look for revert reason and bubble it up if present
            if (returndata.length > 0) {
                // The easiest way to bubble the revert reason is using memory via assembly

                // solhint-disable-next-line no-inline-assembly
                assembly {
                    let returndata_size := mload(returndata)
                    revert(add(32, returndata), returndata_size)
                }
            } else {
                revert(errorMessage);
            }
        }
    }
}
// File: Interfaces/IERC20.sol



pragma solidity ^0.7.0;

/**
 * @dev Interface of the ERC20 standard as defined in the EIP.
 */
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 Moves `amount` tokens from the caller's account to `recipient`.
     *
     * Returns a boolean value indicating whether the operation succeeded.
     *
     * Emits a {Transfer} event.
     */
    function transfer(address recipient, uint256 amount) external returns (bool);

    /**
     * @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.
     */
    function allowance(address owner, address spender) external view returns (uint256);

    /**
     * @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
     * transaction ordering. One possible solution to mitigate this race
     * condition is to first reduce the spender's allowance to 0 and set the
     * desired value afterwards:
     * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729
     *
     * Emits an {Approval} event.
     */
    function approve(address spender, 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.
     */
    function transferFrom(address sender, address recipient, uint256 amount) external returns (bool);

    /**
     * @dev Emitted when `value` tokens are moved from one account (`from`) to
     * another (`to`).
     *
     * Note that `value` may be zero.
     */
    event Transfer(address indexed from, address indexed to, uint256 value);

    /**
     * @dev Emitted when the allowance of a `spender` for an `owner` is set by
     * a call to {approve}. `value` is the new allowance.
     */
    event Approval(address indexed owner, address indexed spender, uint256 value);
}
// File: OpenZeppelin/SafeERC20.sol



pragma solidity ^0.7.0;




/**
 * @title SafeERC20
 * @dev Wrappers around ERC20 operations that throw on failure (when the token
 * contract returns false). Tokens that return no value (and instead revert or
 * throw on failure) are also supported, non-reverting calls are assumed to be
 * successful.
 * To use this library you can add a `using SafeERC20 for IERC20;` statement to your contract,
 * which allows you to call the safe operations as `token.safeTransfer(...)`, etc.
 */
library SafeERC20 {
    using SafeMath for uint256;
    using Address for address;

    function safeTransfer(IERC20 token, address to, uint256 value) internal {
        _callOptionalReturn(token, abi.encodeWithSelector(token.transfer.selector, to, value));
    }

    function safeTransferFrom(IERC20 token, address from, address to, uint256 value) internal {
        _callOptionalReturn(token, abi.encodeWithSelector(token.transferFrom.selector, from, to, value));
    }

    /**
     * @dev Deprecated. This function has issues similar to the ones found in
     * {IERC20-approve}, and its usage is discouraged.
     *
     * Whenever possible, use {safeIncreaseAllowance} and
     * {safeDecreaseAllowance} instead.
     */
    function safeApprove(IERC20 token, address spender, uint256 value) internal {
        // safeApprove should only be called when setting an initial allowance,
        // or when resetting it to zero. To increase and decrease it, use
        // 'safeIncreaseAllowance' and 'safeDecreaseAllowance'
        // solhint-disable-next-line max-line-length
        require((value == 0) || (token.allowance(address(this), spender) == 0),
            "SafeERC20: approve from non-zero to non-zero allowance"
        );
        _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, value));
    }

    function safeIncreaseAllowance(IERC20 token, address spender, uint256 value) internal {
        uint256 newAllowance = token.allowance(address(this), spender).add(value);
        _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance));
    }

    function safeDecreaseAllowance(IERC20 token, address spender, uint256 value) internal {
        uint256 newAllowance = token.allowance(address(this), spender).sub(value, "SafeERC20: decreased allowance below zero");
        _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance));
    }

    /**
     * @dev Imitates a Solidity high-level call (i.e. a regular function call to a contract), relaxing the requirement
     * on the return value: the return value is optional (but if data is returned, it must not be false).
     * @param token The token targeted by the call.
     * @param data The call data (encoded using abi.encode or one of its variants).
     */
    function _callOptionalReturn(IERC20 token, bytes memory data) private {
        // We need to perform a low level call here, to bypass Solidity's return data size checking mechanism, since
        // we're implementing it ourselves. We use {Address.functionCall} to perform this call, which verifies that
        // the target address contains contract code and also asserts for success in the low-level call.

        bytes memory returndata = address(token).functionCall(data, "SafeERC20: low-level call failed");
        if (returndata.length > 0) { // Return data is optional
            // solhint-disable-next-line max-line-length
            require(abi.decode(returndata, (bool)), "SafeERC20: ERC20 operation did not succeed");
        }
    }
}
// File: OpenZeppelin/SafeMath.sol



pragma solidity ^0.7.0;

/**
 * @dev Wrappers over Solidity's arithmetic operations with added overflow
 * checks.
 *
 * Arithmetic operations in Solidity wrap on overflow. This can easily result
 * in bugs, because programmers usually assume that an overflow raises an
 * error, which is the standard behavior in high level programming languages.
 * `SafeMath` restores this intuition by reverting the transaction when an
 * operation overflows.
 *
 * Using this library instead of the unchecked operations eliminates an entire
 * class of bugs, so it's recommended to use it always.
 */
library SafeMath {
    /**
     * @dev Returns the addition of two unsigned integers, reverting on
     * overflow.
     *
     * Counterpart to Solidity's `+` operator.
     *
     * Requirements:
     *
     * - Addition cannot overflow.
     */
    function add(uint256 a, uint256 b) internal pure returns (uint256) {
        uint256 c = a + b;
        require(c >= a, "SafeMath: addition overflow");

        return c;
    }

    /**
     * @dev Returns the subtraction of two unsigned integers, reverting on
     * overflow (when the result is negative).
     *
     * Counterpart to Solidity's `-` operator.
     *
     * Requirements:
     *
     * - Subtraction cannot overflow.
     */
    function sub(uint256 a, uint256 b) internal pure returns (uint256) {
        return sub(a, b, "SafeMath: subtraction overflow");
    }

    /**
     * @dev Returns the subtraction of two unsigned integers, reverting with custom message on
     * overflow (when the result is negative).
     *
     * Counterpart to Solidity's `-` operator.
     *
     * Requirements:
     *
     * - Subtraction cannot overflow.
     */
    function sub(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) {
        require(b <= a, errorMessage);
        uint256 c = a - b;

        return c;
    }

    /**
     * @dev Returns the multiplication of two unsigned integers, reverting on
     * overflow.
     *
     * Counterpart to Solidity's `*` operator.
     *
     * Requirements:
     *
     * - Multiplication cannot overflow.
     */
    function mul(uint256 a, uint256 b) internal pure returns (uint256) {
        // Gas optimization: this is cheaper than requiring 'a' not being zero, but the
        // benefit is lost if 'b' is also tested.
        // See: https://github.com/OpenZeppelin/openzeppelin-contracts/pull/522
        if (a == 0) {
            return 0;
        }

        uint256 c = a * b;
        require(c / a == b, "SafeMath: multiplication overflow");

        return c;
    }

    /**
     * @dev Returns the integer division of two unsigned integers. Reverts on
     * division by zero. The result is rounded towards zero.
     *
     * Counterpart to Solidity's `/` operator. Note: this function uses a
     * `revert` opcode (which leaves remaining gas untouched) while Solidity
     * uses an invalid opcode to revert (consuming all remaining gas).
     *
     * Requirements:
     *
     * - The divisor cannot be zero.
     */
    function div(uint256 a, uint256 b) internal pure returns (uint256) {
        return div(a, b, "SafeMath: division by zero");
    }

    /**
     * @dev Returns the integer division of two unsigned integers. Reverts with custom message on
     * division by zero. The result is rounded towards zero.
     *
     * Counterpart to Solidity's `/` operator. Note: this function uses a
     * `revert` opcode (which leaves remaining gas untouched) while Solidity
     * uses an invalid opcode to revert (consuming all remaining gas).
     *
     * Requirements:
     *
     * - The divisor cannot be zero.
     */
    function div(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) {
        require(b > 0, errorMessage);
        uint256 c = a / b;
        // assert(a == b * c + a % b); // There is no case in which this doesn't hold

        return c;
    }

    /**
     * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),
     * Reverts when dividing by zero.
     *
     * Counterpart to Solidity's `%` operator. This function uses a `revert`
     * opcode (which leaves remaining gas untouched) while Solidity uses an
     * invalid opcode to revert (consuming all remaining gas).
     *
     * Requirements:
     *
     * - The divisor cannot be zero.
     */
    function mod(uint256 a, uint256 b) internal pure returns (uint256) {
        return mod(a, b, "SafeMath: modulo by zero");
    }

    /**
     * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),
     * Reverts with custom message when dividing by zero.
     *
     * Counterpart to Solidity's `%` operator. This function uses a `revert`
     * opcode (which leaves remaining gas untouched) while Solidity uses an
     * invalid opcode to revert (consuming all remaining gas).
     *
     * Requirements:
     *
     * - The divisor cannot be zero.
     */
    function mod(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) {
        require(b != 0, errorMessage);
        return a % b;
    }
}
// File: Diamond/BasketFacet.sol


pragma solidity ^0.7.1;
pragma experimental ABIEncoderV2;

contract BasketFacet is ReentryProtection, CallProtection, IBasketFacet {
    using SafeMath for uint256;
    using SafeERC20 for IERC20;

    uint256 public constant MIN_AMOUNT = 10**6;
    uint256 public constant MAX_ENTRY_FEE = 10**17; // 10%
    uint256 public constant MAX_EXIT_FEE = 10**17; // 10%
    uint256 public constant MAX_ANNUAL_FEE = 10**17; // 10%
    uint256 public constant HUNDRED_PERCENT = 10 ** 18;

    // Assuming a block gas limit of 12M this allows for a gas consumption per token of roughly 333k allowing 2M of overhead for addtional operations
    uint256 public constant MAX_TOKENS = 30;

    function addToken(address _token) external override protectedCall {
        LibBasketStorage.BasketStorage storage bs = LibBasketStorage.basketStorage();
        require(!bs.inPool[_token], "TOKEN_ALREADY_IN_POOL");
        require(bs.tokens.length < MAX_TOKENS, "TOKEN_LIMIT_REACHED");
        // Enforce minimum to avoid rounding errors; (Minimum value is the same as in Balancer)
        require(balance(_token) >= MIN_AMOUNT, "BALANCE_TOO_SMALL");

        bs.inPool[_token] = true;
        bs.tokens.push(IERC20(_token));

        emit TokenAdded(_token);
    }

    function removeToken(address _token) external override protectedCall {
        LibBasketStorage.BasketStorage storage bs = LibBasketStorage.basketStorage();

        require(bs.inPool[_token], "TOKEN_NOT_IN_POOL");

        bs.inPool[_token] = false;

        // remove token from array
        for(uint256 i; i < bs.tokens.length; i ++) {
            if(address(bs.tokens[i]) == _token) {
                bs.tokens[i] = bs.tokens[bs.tokens.length - 1];
                bs.tokens.pop();
                emit TokenRemoved(_token);
                break;
            }
        }
    }

    function setEntryFee(uint256 _fee) external override protectedCall {
        require(_fee <= MAX_ENTRY_FEE, "FEE_TOO_BIG");
        LibBasketStorage.basketStorage().entryFee = _fee;
        emit EntryFeeSet(_fee);
    }

    function getEntryFee() external view override returns(uint256) {
        return LibBasketStorage.basketStorage().entryFee;
    }

    function setExitFee(uint256 _fee) external override protectedCall {
        require(_fee <= MAX_EXIT_FEE, "FEE_TOO_BIG");
        LibBasketStorage.basketStorage().exitFee = _fee;
        emit ExitFeeSet(_fee);
    }

    function getExitFee() external view override returns(uint256) {
        return LibBasketStorage.basketStorage().exitFee;
    }

    function setAnnualizedFee(uint256 _fee) external override protectedCall {
        chargeOutstandingAnnualizedFee();
        require(_fee <= MAX_ANNUAL_FEE, "FEE_TOO_BIG");
        LibBasketStorage.basketStorage().annualizedFee = _fee;
        emit AnnualizedFeeSet(_fee);
    }

    function getAnnualizedFee() external view override returns(uint256) {
        return LibBasketStorage.basketStorage().annualizedFee;
    }

    function setFeeBeneficiary(address _beneficiary) external override protectedCall {
        chargeOutstandingAnnualizedFee();
        LibBasketStorage.basketStorage().feeBeneficiary = _beneficiary;
        emit FeeBeneficiarySet(_beneficiary);
    }

    function getFeeBeneficiary() external view override returns(address) {
        return LibBasketStorage.basketStorage().feeBeneficiary;
    }

    function setEntryFeeBeneficiaryShare(uint256 _share) external override protectedCall {
        require(_share <= HUNDRED_PERCENT, "FEE_SHARE_TOO_BIG");
        LibBasketStorage.basketStorage().entryFeeBeneficiaryShare = _share;
        emit EntryFeeBeneficiaryShareSet(_share);
    }

    function getEntryFeeBeneficiaryShare() external view override returns(uint256) {
        return LibBasketStorage.basketStorage().entryFeeBeneficiaryShare;
    }

    function setExitFeeBeneficiaryShare(uint256 _share) external override protectedCall {
        require(_share <= HUNDRED_PERCENT, "FEE_SHARE_TOO_BIG");
        LibBasketStorage.basketStorage().exitFeeBeneficiaryShare = _share;
        emit ExitFeeBeneficiaryShareSet(_share);
    }

    function getExitFeeBeneficiaryShare() external view override returns(uint256) {
        return LibBasketStorage.basketStorage().exitFeeBeneficiaryShare;
    }


    function joinPool(uint256 _amount) external override noReentry {
        require(!this.getLock(), "POOL_LOCKED");
        chargeOutstandingAnnualizedFee();
        LibBasketStorage.BasketStorage storage bs = LibBasketStorage.basketStorage();
        uint256 totalSupply = LibERC20Storage.erc20Storage().totalSupply;
        require(totalSupply.add(_amount) <= this.getCap(), "MAX_POOL_CAP_REACHED");

        uint256 feeAmount = _amount.mul(bs.entryFee).div(10**18);

        for(uint256 i; i < bs.tokens.length; i ++) {
            IERC20 token = bs.tokens[i];
            uint256 tokenAmount = balance(address(token)).mul(_amount.add(feeAmount)).div(totalSupply);
            require(tokenAmount != 0, "AMOUNT_TOO_SMALL");
            token.safeTransferFrom(msg.sender, address(this), tokenAmount);
        }

        // If there is any fee that should go to the beneficiary mint it
        if(
            feeAmount != 0 &&
            bs.entryFeeBeneficiaryShare != 0 &&
            bs.feeBeneficiary != address(0)
        ) {
            uint256 feeBeneficiaryShare = feeAmount.mul(bs.entryFeeBeneficiaryShare).div(10**18);
            if(feeBeneficiaryShare != 0) {
                LibERC20.mint(bs.feeBeneficiary, feeBeneficiaryShare);
            }
        }

        LibERC20.mint(msg.sender, _amount);
        emit PoolJoined(msg.sender, _amount);
    }

    // Must be overwritten to withdraw from strategies
    function exitPool(uint256 _amount) external override virtual noReentry {
        require(!this.getLock(), "POOL_LOCKED");
        chargeOutstandingAnnualizedFee();
        LibBasketStorage.BasketStorage storage bs = LibBasketStorage.basketStorage();
        uint256 totalSupply = LibERC20Storage.erc20Storage().totalSupply;

        uint256 feeAmount = _amount.mul(bs.exitFee).div(10**18);

        for(uint256 i; i < bs.tokens.length; i ++) {
            IERC20 token = bs.tokens[i];
            uint256 tokenBalance = balance(address(token));
            // redeem less tokens if there is an exit fee
            uint256 tokenAmount = tokenBalance.mul(_amount.sub(feeAmount)).div(totalSupply);
            require(tokenBalance.sub(tokenAmount) >= MIN_AMOUNT, "TOKEN_BALANCE_TOO_LOW");
            token.safeTransfer(msg.sender, tokenAmount);
        }

         // If there is any fee that should go to the beneficiary mint it
        if(
            feeAmount != 0 &&
            bs.exitFeeBeneficiaryShare != 0 &&
            bs.feeBeneficiary != address(0)
        ) {
            uint256 feeBeneficiaryShare = feeAmount.mul(bs.exitFeeBeneficiaryShare).div(10**18);
            if(feeBeneficiaryShare != 0) {
                LibERC20.mint(bs.feeBeneficiary, feeBeneficiaryShare);
            }
        }

        require(totalSupply.sub(_amount) >= MIN_AMOUNT, "POOL_TOKEN_BALANCE_TOO_LOW");
        LibERC20.burn(msg.sender, _amount);
        emit PoolExited(msg.sender, _amount);
    }


    function calcOutStandingAnnualizedFee() public view override returns(uint256) {
        LibBasketStorage.BasketStorage storage bs = LibBasketStorage.basketStorage();
        uint256 totalSupply = LibERC20Storage.erc20Storage().totalSupply;

        uint256 lastFeeClaimed = bs.lastAnnualizedFeeClaimed;
        uint256 annualizedFee = bs.annualizedFee;

        if(
            annualizedFee == 0 ||
            bs.feeBeneficiary == address(0) ||
            lastFeeClaimed == 0
        ) {
            return 0;
        }

        uint256 timePassed = block.timestamp.sub(lastFeeClaimed);

        return totalSupply.mul(annualizedFee).div(10**18).mul(timePassed).div(365 days);
    }

    function chargeOutstandingAnnualizedFee() public override {
        uint256 outStandingFee = calcOutStandingAnnualizedFee();
        LibBasketStorage.BasketStorage storage bs = LibBasketStorage.basketStorage();

        bs.lastAnnualizedFeeClaimed = block.timestamp;

        // if there is any fee to mint and the beneficiary is set
        // note: feeBeneficiary is already checked in calc function
        if(
            outStandingFee != 0
        ) {
            LibERC20.mint(bs.feeBeneficiary, outStandingFee);
        }

        emit FeeCharged(outStandingFee);
    }

    // returns true when locked
    function getLock() external view override returns(bool) {
        LibBasketStorage.BasketStorage storage bs = LibBasketStorage.basketStorage();
        return bs.lockBlock == 0 || bs.lockBlock >= block.number;
    }

    function getTokenInPool(address _token) external view override returns(bool) {
        return LibBasketStorage.basketStorage().inPool[_token];
    }

    function getLockBlock() external view override returns(uint256) {
        return LibBasketStorage.basketStorage().lockBlock;
    }

    // lock up to and including _lock blocknumber
    function setLock(uint256 _lock) external override protectedCall {
        LibBasketStorage.basketStorage().lockBlock = _lock;
        emit LockSet(_lock);
    }

    function setCap(uint256 _maxCap) external override protectedCall {
        LibBasketStorage.basketStorage().maxCap = _maxCap;
        emit CapSet(_maxCap);
    }

    // Seperated balance function to allow yearn like strategies to be hooked up by inheriting from this contract and overriding
    function balance(address _token) public view override returns(uint256) {
        return IERC20(_token).balanceOf(address(this));
    }

    function getTokens() external view override returns (address[] memory) {
        IERC20[] memory tokens = LibBasketStorage.basketStorage().tokens;
        address[] memory result = new address[](tokens.length);

        for(uint256 i = 0; i < tokens.length; i ++) {
            result[i] = address(tokens[i]);
        }

        return(result);
    }

    function getCap() external view override returns(uint256){
        return LibBasketStorage.basketStorage().maxCap;
    }

    function calcTokensForAmount(uint256 _amount) external view override returns (address[] memory tokens, uint256[] memory amounts) {
        LibBasketStorage.BasketStorage storage bs = LibBasketStorage.basketStorage();
        uint256 totalSupply = LibERC20Storage.erc20Storage().totalSupply.add(calcOutStandingAnnualizedFee());

        tokens = new address[](bs.tokens.length);
        amounts = new uint256[](bs.tokens.length);

        for(uint256 i; i < bs.tokens.length; i ++) {
            IERC20 token = bs.tokens[i];
            uint256 tokenBalance = balance(address(token));
            uint256 tokenAmount = tokenBalance.mul(_amount).div(totalSupply);
            // Add entry fee
            tokenAmount = tokenAmount.add(tokenAmount.mul(bs.entryFee).div(10**18));

            tokens[i] = address(token);
            amounts[i] = tokenAmount;
        }

        return(tokens, amounts);
    }

    function calcTokensForAmountExit(uint256 _amount) external view override returns (address[] memory tokens, uint256[] memory amounts) {
        LibBasketStorage.BasketStorage storage bs = LibBasketStorage.basketStorage();
        uint256 feeAmount = _amount.mul(bs.exitFee).div(10**18);
        uint256 totalSupply = LibERC20Storage.erc20Storage().totalSupply.add(calcOutStandingAnnualizedFee());

        tokens = new address[](bs.tokens.length);
        amounts = new uint256[](bs.tokens.length);

        for(uint256 i; i < bs.tokens.length; i ++) {
            IERC20 token = bs.tokens[i];
            uint256 tokenBalance = balance(address(token));
            uint256 tokenAmount = tokenBalance.mul(_amount.sub(feeAmount)).div(totalSupply);

            tokens[i] = address(token);
            amounts[i] = tokenAmount;
        }

        return(tokens, amounts);
    }
}

Contract Security Audit

Contract ABI

[{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"fee","type":"uint256"}],"name":"AnnualizedFeeSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"cap","type":"uint256"}],"name":"CapSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"share","type":"uint256"}],"name":"EntryFeeBeneficiaryShareSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"fee","type":"uint256"}],"name":"EntryFeeSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"share","type":"uint256"}],"name":"ExitFeeBeneficiaryShareSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"fee","type":"uint256"}],"name":"ExitFeeSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"beneficiary","type":"address"}],"name":"FeeBeneficiarySet","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"FeeCharged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"lockBlock","type":"uint256"}],"name":"LockSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"who","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"PoolExited","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"who","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"PoolJoined","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"_token","type":"address"}],"name":"TokenAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"_token","type":"address"}],"name":"TokenRemoved","type":"event"},{"inputs":[],"name":"HUNDRED_PERCENT","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAX_ANNUAL_FEE","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAX_ENTRY_FEE","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAX_EXIT_FEE","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAX_TOKENS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MIN_AMOUNT","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_token","type":"address"}],"name":"addToken","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_token","type":"address"}],"name":"balance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"calcOutStandingAnnualizedFee","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"calcTokensForAmount","outputs":[{"internalType":"address[]","name":"tokens","type":"address[]"},{"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"calcTokensForAmountExit","outputs":[{"internalType":"address[]","name":"tokens","type":"address[]"},{"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"chargeOutstandingAnnualizedFee","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"exitPool","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"getAnnualizedFee","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getCap","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getEntryFee","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getEntryFeeBeneficiaryShare","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getExitFee","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getExitFeeBeneficiaryShare","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getFeeBeneficiary","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getLock","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getLockBlock","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_token","type":"address"}],"name":"getTokenInPool","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getTokens","outputs":[{"internalType":"address[]","name":"","type":"address[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"joinPool","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_token","type":"address"}],"name":"removeToken","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_fee","type":"uint256"}],"name":"setAnnualizedFee","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_maxCap","type":"uint256"}],"name":"setCap","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_fee","type":"uint256"}],"name":"setEntryFee","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_share","type":"uint256"}],"name":"setEntryFeeBeneficiaryShare","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_fee","type":"uint256"}],"name":"setExitFee","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_share","type":"uint256"}],"name":"setExitFeeBeneficiaryShare","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_beneficiary","type":"address"}],"name":"setFeeBeneficiary","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_lock","type":"uint256"}],"name":"setLock","outputs":[],"stateMutability":"nonpayable","type":"function"}]

608060405234801561001057600080fd5b50613f43806100206000396000f3fe608060405234801561001057600080fd5b50600436106102065760003560e01c8063ad293cf21161011a578063e586a4f0116100ad578063ecb0116a1161007c578063ecb0116a14610593578063ef512424146105b1578063f47c84c5146105cd578063f50ab0de146105eb578063fff3087c1461060957610206565b8063e586a4f01461051f578063e5a583a91461053d578063eb770d0c14610559578063ec9c2b391461057557610206565b8063d48bfca7116100e9578063d48bfca714610497578063d908c3e5146104b3578063ddbcb5fa146104d1578063e3d670d7146104ef57610206565b8063ad293cf214610411578063aecb93561461042f578063be1d24ad1461045f578063d3e157471461047b57610206565b80635a0a3d821161019d5780637e5852d91161016c5780637e5852d91461037d5780638a8257dd1461039b5780639baf58d2146103b75780639d3f7dd4146103d5578063aa6ca808146103f357610206565b80635a0a3d821461031d5780635d44c9cb146103395780635fa7b584146103435780636ed93dd01461035f57610206565b80633809283a116101d95780633809283a146102a757806347786d37146102c5578063554d578d146102e1578063560ad134146102ff57610206565b806323817b8e1461020b57806334e7a19f1461023c578063366254e814610258578063371babdc14610276575b600080fd5b61022560048036038101906102209190613330565b610625565b604051610233929190613ac9565b60405180910390f35b61025660048036038101906102519190613330565b610843565b005b610260610cf5565b60405161026d9190613d7d565b60405180910390f35b610290600480360381019061028b9190613330565b610d08565b60405161029e929190613ac9565b60405180910390f35b6102af610f23565b6040516102bc9190613d7d565b60405180910390f35b6102df60048036038101906102da9190613330565b610f2f565b005b6102e9611048565b6040516102f69190613d7d565b60405180910390f35b61030761105b565b6040516103149190613d7d565b60405180910390f35b610337600480360381019061033291906132de565b61106e565b005b6103416111d5565b005b61035d600480360381019061035891906132de565b611268565b005b6103676115e1565b6040516103749190613d7d565b60405180910390f35b6103856115ed565b6040516103929190613b00565b60405180910390f35b6103b560048036038101906103b09190613330565b611617565b005b6103bf61177b565b6040516103cc9190613d7d565b60405180910390f35b6103dd611787565b6040516103ea9190613d7d565b60405180910390f35b6103fb61179a565b6040516104089190613aa7565b60405180910390f35b6104196118f7565b6040516104269190613d7d565b60405180910390f35b610449600480360381019061044491906132de565b61190a565b6040516104569190613b00565b60405180910390f35b61047960048036038101906104749190613330565b611969565b005b61049560048036038101906104909190613330565b611db9565b005b6104b160048036038101906104ac91906132de565b611ed2565b005b6104bb6121da565b6040516104c89190613a2c565b60405180910390f35b6104d961220d565b6040516104e69190613d7d565b60405180910390f35b610509600480360381019061050491906132de565b612214565b6040516105169190613d7d565b60405180910390f35b6105276122a6565b6040516105349190613d7d565b60405180910390f35b61055760048036038101906105529190613330565b6122b9565b005b610573600480360381019061056e9190613330565b61241d565b005b61057d612581565b60405161058a9190613d7d565b60405180910390f35b61059b6126a3565b6040516105a89190613d7d565b60405180910390f35b6105cb60048036038101906105c69190613330565b6126b6565b005b6105d5612822565b6040516105e29190613d7d565b60405180910390f35b6105f3612827565b6040516106009190613d7d565b60405180910390f35b610623600480360381019061061e9190613330565b612833565b005b6060806000610632612997565b90506000610667670de0b6b3a76400006106598460060154886129c490919063ffffffff16565b612a3490919063ffffffff16565b90506000610690610676612581565b61067e612a7e565b60020154612aab90919063ffffffff16565b9050826002018054905067ffffffffffffffff811180156106b057600080fd5b506040519080825280602002602001820160405280156106df5781602001602082028036833780820191505090505b509450826002018054905067ffffffffffffffff8111801561070057600080fd5b5060405190808252806020026020018201604052801561072f5781602001602082028036833780820191505090505b50935060005b836002018054905081101561083a57600084600201828154811061075557fe5b9060005260206000200160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050600061078d82612214565b905060006107c8856107ba6107ab898e612b0090919063ffffffff16565b856129c490919063ffffffff16565b612a3490919063ffffffff16565b9050828985815181106107d757fe5b602002602001019073ffffffffffffffffffffffffffffffffffffffff16908173ffffffffffffffffffffffffffffffffffffffff16815250508088858151811061081e57fe5b6020026020010181815250505050508080600101915050610735565b50505050915091565b600061084d612b4a565b905080600001600081548092919060010191905055506000816000015490503073ffffffffffffffffffffffffffffffffffffffff16637e5852d96040518163ffffffff1660e01b815260040160206040518083038186803b1580156108b257600080fd5b505afa1580156108c6573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906108ea9190613307565b1561092a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161092190613c5d565b60405180910390fd5b6109326111d5565b600061093c612997565b90506000610948612a7e565b6002015490503073ffffffffffffffffffffffffffffffffffffffff1663554d578d6040518163ffffffff1660e01b815260040160206040518083038186803b15801561099457600080fd5b505afa1580156109a8573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906109cc9190613359565b6109df8683612aab90919063ffffffff16565b1115610a20576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610a1790613b7d565b60405180910390fd5b6000610a53670de0b6b3a7640000610a458560040154896129c490919063ffffffff16565b612a3490919063ffffffff16565b905060005b8360020180549050811015610b68576000846002018281548110610a7857fe5b9060005260206000200160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1690506000610ae685610ad8610ac1878d612aab90919063ffffffff16565b610aca86612214565b6129c490919063ffffffff16565b612a3490919063ffffffff16565b90506000811415610b2c576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610b2390613b5d565b60405180910390fd5b610b593330838573ffffffffffffffffffffffffffffffffffffffff16612b77909392919063ffffffff16565b50508080600101915050610a58565b5060008114158015610b7f57506000836005015414155b8015610bdc5750600073ffffffffffffffffffffffffffffffffffffffff1683600a0160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614155b15610c4f576000610c14670de0b6b3a7640000610c068660050154856129c490919063ffffffff16565b612a3490919063ffffffff16565b905060008114610c4d57610c4c84600a0160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1682612c00565b5b505b610c593387612c00565b3373ffffffffffffffffffffffffffffffffffffffff167f7a011ddbb8da163de89faccb018bb75c616e6ac270738b8bf1785f08ae1b2d6f87604051610c9f9190613d7d565b60405180910390a250505081600001548114610cf0576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610ce790613d3d565b60405180910390fd5b505050565b6000610cff612997565b60070154905090565b6060806000610d15612997565b90506000610d3e610d24612581565b610d2c612a7e565b60020154612aab90919063ffffffff16565b9050816002018054905067ffffffffffffffff81118015610d5e57600080fd5b50604051908082528060200260200182016040528015610d8d5781602001602082028036833780820191505090505b509350816002018054905067ffffffffffffffff81118015610dae57600080fd5b50604051908082528060200260200182016040528015610ddd5781602001602082028036833780820191505090505b50925060005b8260020180549050811015610f1b576000836002018281548110610e0357fe5b9060005260206000200160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1690506000610e3b82612214565b90506000610e6485610e568b856129c490919063ffffffff16565b612a3490919063ffffffff16565b9050610ea9610e9a670de0b6b3a7640000610e8c8960040154856129c490919063ffffffff16565b612a3490919063ffffffff16565b82612aab90919063ffffffff16565b905082888581518110610eb857fe5b602002602001019073ffffffffffffffffffffffffffffffffffffffff16908173ffffffffffffffffffffffffffffffffffffffff168152505080878581518110610eff57fe5b6020026020010181815250505050508080600101915050610de3565b505050915091565b67016345785d8a000081565b610f37612d9f565b60040160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161480610fbf57503073ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16145b610ffe576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610ff590613c1d565b60405180910390fd5b80611007612997565b600101819055507f9872d5eb566b79923d043f1b59aca655ca80a2bb5b6bca4824e515b0e398902f8160405161103d9190613d7d565b60405180910390a150565b6000611052612997565b60010154905090565b6000611065612997565b60000154905090565b611076612d9f565b60040160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614806110fe57503073ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16145b61113d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161113490613c1d565b60405180910390fd5b6111456111d5565b8061114e612997565b600a0160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508073ffffffffffffffffffffffffffffffffffffffff167ff7015098f8d6fa48f0560725ffd5f81bf687ee5ac45153b590bdcb04648bbdd360405160405180910390a250565b60006111df612581565b905060006111eb612997565b90504281600901819055506000821461122d5761122c81600a0160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1683612c00565b5b7fccac4111799e8a37144a6ae9e90ea146dcd86f34f155783a8ce97c546ad8c2fe8260405161125c9190613d7d565b60405180910390a15050565b611270612d9f565b60040160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614806112f857503073ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16145b611337576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161132e90613c1d565b60405180910390fd5b6000611341612997565b90508060030160008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff166113d1576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016113c890613d5d565b60405180910390fd5b60008160030160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff02191690831515021790555060005b81600201805490508110156115dc578273ffffffffffffffffffffffffffffffffffffffff1682600201828154811061146357fe5b9060005260206000200160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614156115cf57816002016001836002018054905003815481106114c357fe5b9060005260206000200160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff168260020182815481106114fd57fe5b9060005260206000200160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508160020180548061155257fe5b6001900381819060005260206000200160006101000a81549073ffffffffffffffffffffffffffffffffffffffff021916905590558273ffffffffffffffffffffffffffffffffffffffff167f4c910b69fe65a61f7531b9c5042b2329ca7179c77290aa7e2eb3afa3c8511fd360405160405180910390a26115dc565b808060010191505061142e565b505050565b670de0b6b3a764000081565b6000806115f8612997565b9050600081600001541480611611575043816000015410155b91505090565b61161f612d9f565b60040160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614806116a757503073ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16145b6116e6576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016116dd90613c1d565b60405180910390fd5b670de0b6b3a7640000811115611731576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161172890613c9d565b60405180910390fd5b8061173a612997565b600501819055507f34099db0e58e33c67a0ceae8361ed3a1d587d9fb194626eb7d65ecd51fa4f4d7816040516117709190613d7d565b60405180910390a150565b67016345785d8a000081565b6000611791612997565b60050154905090565b6060806117a5612997565b60020180548060200260200160405190810160405280929190818152602001828054801561182857602002820191906000526020600020905b8160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190600101908083116117de575b505050505090506060815167ffffffffffffffff8111801561184957600080fd5b506040519080825280602002602001820160405280156118785781602001602082028036833780820191505090505b50905060005b82518110156118ee5782818151811061189357fe5b60200260200101518282815181106118a757fe5b602002602001019073ffffffffffffffffffffffffffffffffffffffff16908173ffffffffffffffffffffffffffffffffffffffff1681525050808060010191505061187e565b50809250505090565b6000611901612997565b60080154905090565b6000611914612997565b60030160008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff169050919050565b6000611973612b4a565b905080600001600081548092919060010191905055506000816000015490503073ffffffffffffffffffffffffffffffffffffffff16637e5852d96040518163ffffffff1660e01b815260040160206040518083038186803b1580156119d857600080fd5b505afa1580156119ec573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611a109190613307565b15611a50576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611a4790613c5d565b60405180910390fd5b611a586111d5565b6000611a62612997565b90506000611a6e612a7e565b6002015490506000611aa7670de0b6b3a7640000611a998560060154896129c490919063ffffffff16565b612a3490919063ffffffff16565b905060005b8360020180549050811015611bd4576000846002018281548110611acc57fe5b9060005260206000200160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1690506000611b0482612214565b90506000611b3f86611b31611b22888e612b0090919063ffffffff16565b856129c490919063ffffffff16565b612a3490919063ffffffff16565b9050620f4240611b588284612b0090919063ffffffff16565b1015611b99576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611b9090613c7d565b60405180910390fd5b611bc433828573ffffffffffffffffffffffffffffffffffffffff16612dcc9092919063ffffffff16565b5050508080600101915050611aac565b5060008114158015611beb57506000836007015414155b8015611c485750600073ffffffffffffffffffffffffffffffffffffffff1683600a0160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614155b15611cbb576000611c80670de0b6b3a7640000611c728660070154856129c490919063ffffffff16565b612a3490919063ffffffff16565b905060008114611cb957611cb884600a0160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1682612c00565b5b505b620f4240611cd28784612b0090919063ffffffff16565b1015611d13576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611d0a90613cdd565b60405180910390fd5b611d1d3387612e52565b3373ffffffffffffffffffffffffffffffffffffffff167fbc865856a1e9f1dfe2abde98edc2eefe87b6c391a47032388ef36d8c2474aad387604051611d639190613d7d565b60405180910390a250505081600001548114611db4576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611dab90613d3d565b60405180910390fd5b505050565b611dc1612d9f565b60040160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161480611e4957503073ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16145b611e88576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611e7f90613c1d565b60405180910390fd5b80611e91612997565b600001819055507fc96ac8f962bbb0ee952304839108c72982a49173fa73e62ede62c943e10f574281604051611ec79190613d7d565b60405180910390a150565b611eda612d9f565b60040160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161480611f6257503073ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16145b611fa1576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611f9890613c1d565b60405180910390fd5b6000611fab612997565b90508060030160008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff161561203c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161203390613b3d565b60405180910390fd5b601e816002018054905010612086576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161207d90613bdd565b60405180910390fd5b620f424061209383612214565b10156120d4576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016120cb90613cfd565b60405180910390fd5b60018160030160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff02191690831515021790555080600201829080600181540180825580915050600190039060005260206000200160009091909190916101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff167f784c8f4dbf0ffedd6e72c76501c545a70f8b203b30a26ce542bf92ba87c248a460405160405180910390a25050565b60006121e4612997565b600a0160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b620f424081565b60008173ffffffffffffffffffffffffffffffffffffffff166370a08231306040518263ffffffff1660e01b815260040161224f9190613a2c565b60206040518083038186803b15801561226757600080fd5b505afa15801561227b573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061229f9190613359565b9050919050565b60006122b0612997565b60040154905090565b6122c1612d9f565b60040160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16148061234957503073ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16145b612388576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161237f90613c1d565b60405180910390fd5b67016345785d8a00008111156123d3576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016123ca90613bbd565b60405180910390fd5b806123dc612997565b600601819055507fb087f15d44c22304a275c2b80bad7d5ccfd7059fa7678aa84549b55f614a158c816040516124129190613d7d565b60405180910390a150565b612425612d9f565b60040160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614806124ad57503073ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16145b6124ec576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016124e390613c1d565b60405180910390fd5b67016345785d8a0000811115612537576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161252e90613bbd565b60405180910390fd5b80612540612997565b600401819055507f565a4bfd76b3419546eefb0f3228d436837362a9b57e0c3a03227225dfec023d816040516125769190613d7d565b60405180910390a150565b60008061258c612997565b90506000612598612a7e565b600201549050600082600901549050600083600801549050600081148061260f5750600073ffffffffffffffffffffffffffffffffffffffff1684600a0160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16145b8061261a5750600082145b1561262c5760009450505050506126a0565b60006126418342612b0090919063ffffffff16565b90506126986301e1338061268a8361267c670de0b6b3a764000061266e888b6129c490919063ffffffff16565b612a3490919063ffffffff16565b6129c490919063ffffffff16565b612a3490919063ffffffff16565b955050505050505b90565b60006126ad612997565b60060154905090565b6126be612d9f565b60040160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16148061274657503073ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16145b612785576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161277c90613c1d565b60405180910390fd5b61278d6111d5565b67016345785d8a00008111156127d8576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016127cf90613bbd565b60405180910390fd5b806127e1612997565b600801819055507fb28ff79de60b96320a73afead226d63eff6efb0af3c1ce70c7e2e5489419e113816040516128179190613d7d565b60405180910390a150565b601e81565b67016345785d8a000081565b61283b612d9f565b60040160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614806128c357503073ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16145b612902576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016128f990613c1d565b60405180910390fd5b670de0b6b3a764000081111561294d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161294490613c9d565b60405180910390fd5b80612956612997565b600701819055507f5dfdebaeccd5926e0513268bf319e64f404ccc739f1344dbd895cd6a1c4ede8c8160405161298c9190613d7d565b60405180910390a150565b6000807f1cdb335291b9ba9e18468a78cd32d3a9c32fd7cc42984115c04be356ede766ac90508091505090565b6000808314156129d75760009050612a2e565b60008284029050828482816129e857fe5b0414612a29576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401612a2090613c3d565b60405180910390fd5b809150505b92915050565b6000612a7683836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f000000000000815250612f81565b905092915050565b6000807f41d2dff3392a31ed3dbbccd2b0d803b57f5635d0ccd048fd68edf9f4d37c1b9f90508091505090565b600080828401905083811015612af6576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401612aed90613b9d565b60405180910390fd5b8091505092915050565b6000612b4283836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f770000815250612fe2565b905092915050565b6000807ffad169404002d10c88c6f4c5df96a5ae8d3cada85765079fe73839a09bf6887c90508091505090565b612bfa846323b872dd60e01b858585604051602401612b9893929190613a47565b604051602081830303815290604052907bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff838183161783525050505061303d565b50505050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415612c70576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401612c6790613bfd565b60405180910390fd5b6000612c7a612a7e565b9050612cd0828260030160008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054612aab90919063ffffffff16565b8160030160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550612d2c828260020154612aab90919063ffffffff16565b81600201819055508273ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef84604051612d929190613d7d565b60405180910390a3505050565b6000807fc8fcad8db84d3cc18b4c41d551ea0ee66dd599cde068d998e57d5e09332c131c90508091505090565b612e4d8363a9059cbb60e01b8484604051602401612deb929190613a7e565b604051602081830303815290604052907bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff838183161783525050505061303d565b505050565b6000612e5c612a7e565b9050612eb2828260030160008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054612b0090919063ffffffff16565b8160030160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550612f0e828260020154612b0090919063ffffffff16565b8160020181905550600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef84604051612f749190613d7d565b60405180910390a3505050565b60008083118290612fc8576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401612fbf9190613b1b565b60405180910390fd5b506000838581612fd457fe5b049050809150509392505050565b600083831115829061302a576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016130219190613b1b565b60405180910390fd5b5060008385039050809150509392505050565b606061309f826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c65648152508573ffffffffffffffffffffffffffffffffffffffff166131049092919063ffffffff16565b90506000815111156130ff57808060200190518101906130bf9190613307565b6130fe576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016130f590613d1d565b60405180910390fd5b5b505050565b6060613113848460008561311c565b90509392505050565b60606131278561323f565b613166576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161315d90613cbd565b60405180910390fd5b600060608673ffffffffffffffffffffffffffffffffffffffff1685876040516131909190613a15565b60006040518083038185875af1925050503d80600081146131cd576040519150601f19603f3d011682016040523d82523d6000602084013e6131d2565b606091505b509150915081156131e7578092505050613237565b6000815111156131fa5780518082602001fd5b836040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161322e9190613b1b565b60405180910390fd5b949350505050565b60008060007fc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a47060001b9050833f915080821415801561328157506000801b8214155b92505050919050565b60008135905061329981613ec8565b92915050565b6000815190506132ae81613edf565b92915050565b6000813590506132c381613ef6565b92915050565b6000815190506132d881613ef6565b92915050565b6000602082840312156132f057600080fd5b60006132fe8482850161328a565b91505092915050565b60006020828403121561331957600080fd5b60006133278482850161329f565b91505092915050565b60006020828403121561334257600080fd5b6000613350848285016132b4565b91505092915050565b60006020828403121561336b57600080fd5b6000613379848285016132c9565b91505092915050565b600061338e83836133b2565b60208301905092915050565b60006133a683836139f7565b60208301905092915050565b6133bb81613e3c565b82525050565b6133ca81613e3c565b82525050565b60006133db82613db8565b6133e58185613dfe565b93506133f083613d98565b8060005b838110156134215781516134088882613382565b975061341383613de4565b9250506001810190506133f4565b5085935050505092915050565b600061343982613dc3565b6134438185613e0f565b935061344e83613da8565b8060005b8381101561347f578151613466888261339a565b975061347183613df1565b925050600181019050613452565b5085935050505092915050565b61349581613e4e565b82525050565b60006134a682613dce565b6134b08185613e20565b93506134c0818560208601613e84565b80840191505092915050565b60006134d782613dd9565b6134e18185613e2b565b93506134f1818560208601613e84565b6134fa81613eb7565b840191505092915050565b6000613512601583613e2b565b91507f544f4b454e5f414c52454144595f494e5f504f4f4c00000000000000000000006000830152602082019050919050565b6000613552601083613e2b565b91507f414d4f554e545f544f4f5f534d414c4c000000000000000000000000000000006000830152602082019050919050565b6000613592601483613e2b565b91507f4d41585f504f4f4c5f4341505f524541434845440000000000000000000000006000830152602082019050919050565b60006135d2601b83613e2b565b91507f536166654d6174683a206164646974696f6e206f766572666c6f7700000000006000830152602082019050919050565b6000613612600b83613e2b565b91507f4645455f544f4f5f4249470000000000000000000000000000000000000000006000830152602082019050919050565b6000613652601383613e2b565b91507f544f4b454e5f4c494d49545f52454143484544000000000000000000000000006000830152602082019050919050565b6000613692601283613e2b565b91507f494e56414c49445f544f5f4144445245535300000000000000000000000000006000830152602082019050919050565b60006136d2600b83613e2b565b91507f4e4f545f414c4c4f5745440000000000000000000000000000000000000000006000830152602082019050919050565b6000613712602183613e2b565b91507f536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f60008301527f77000000000000000000000000000000000000000000000000000000000000006020830152604082019050919050565b6000613778600b83613e2b565b91507f504f4f4c5f4c4f434b45440000000000000000000000000000000000000000006000830152602082019050919050565b60006137b8601583613e2b565b91507f544f4b454e5f42414c414e43455f544f4f5f4c4f5700000000000000000000006000830152602082019050919050565b60006137f8601183613e2b565b91507f4645455f53484152455f544f4f5f4249470000000000000000000000000000006000830152602082019050919050565b6000613838601d83613e2b565b91507f416464726573733a2063616c6c20746f206e6f6e2d636f6e74726163740000006000830152602082019050919050565b6000613878601a83613e2b565b91507f504f4f4c5f544f4b454e5f42414c414e43455f544f4f5f4c4f570000000000006000830152602082019050919050565b60006138b8601183613e2b565b91507f42414c414e43455f544f4f5f534d414c4c0000000000000000000000000000006000830152602082019050919050565b60006138f8602a83613e2b565b91507f5361666545524332303a204552433230206f7065726174696f6e20646964206e60008301527f6f742073756363656564000000000000000000000000000000000000000000006020830152604082019050919050565b600061395e603283613e2b565b91507f5265656e74727950726f74656374696f6e46616365742e6e6f5265656e74727960008301527f3a207265656e74727920646574656374656400000000000000000000000000006020830152604082019050919050565b60006139c4601183613e2b565b91507f544f4b454e5f4e4f545f494e5f504f4f4c0000000000000000000000000000006000830152602082019050919050565b613a0081613e7a565b82525050565b613a0f81613e7a565b82525050565b6000613a21828461349b565b915081905092915050565b6000602082019050613a4160008301846133c1565b92915050565b6000606082019050613a5c60008301866133c1565b613a6960208301856133c1565b613a766040830184613a06565b949350505050565b6000604082019050613a9360008301856133c1565b613aa06020830184613a06565b9392505050565b60006020820190508181036000830152613ac181846133d0565b905092915050565b60006040820190508181036000830152613ae381856133d0565b90508181036020830152613af7818461342e565b90509392505050565b6000602082019050613b15600083018461348c565b92915050565b60006020820190508181036000830152613b3581846134cc565b905092915050565b60006020820190508181036000830152613b5681613505565b9050919050565b60006020820190508181036000830152613b7681613545565b9050919050565b60006020820190508181036000830152613b9681613585565b9050919050565b60006020820190508181036000830152613bb6816135c5565b9050919050565b60006020820190508181036000830152613bd681613605565b9050919050565b60006020820190508181036000830152613bf681613645565b9050919050565b60006020820190508181036000830152613c1681613685565b9050919050565b60006020820190508181036000830152613c36816136c5565b9050919050565b60006020820190508181036000830152613c5681613705565b9050919050565b60006020820190508181036000830152613c768161376b565b9050919050565b60006020820190508181036000830152613c96816137ab565b9050919050565b60006020820190508181036000830152613cb6816137eb565b9050919050565b60006020820190508181036000830152613cd68161382b565b9050919050565b60006020820190508181036000830152613cf68161386b565b9050919050565b60006020820190508181036000830152613d16816138ab565b9050919050565b60006020820190508181036000830152613d36816138eb565b9050919050565b60006020820190508181036000830152613d5681613951565b9050919050565b60006020820190508181036000830152613d76816139b7565b9050919050565b6000602082019050613d926000830184613a06565b92915050565b6000819050602082019050919050565b6000819050602082019050919050565b600081519050919050565b600081519050919050565b600081519050919050565b600081519050919050565b6000602082019050919050565b6000602082019050919050565b600082825260208201905092915050565b600082825260208201905092915050565b600081905092915050565b600082825260208201905092915050565b6000613e4782613e5a565b9050919050565b60008115159050919050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000819050919050565b60005b83811015613ea2578082015181840152602081019050613e87565b83811115613eb1576000848401525b50505050565b6000601f19601f8301169050919050565b613ed181613e3c565b8114613edc57600080fd5b50565b613ee881613e4e565b8114613ef357600080fd5b50565b613eff81613e7a565b8114613f0a57600080fd5b5056fea2646970667358221220719af08339555ff8d4aecbaeea4e16017e54385acfc1f5c255cd2d9d95ae1eb864736f6c63430007010033

Deployed ByteCode Sourcemap

41442:12182:0:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;52729:892;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;;;;;;;:::i;:::-;;;;;;;;45774:1393;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;45604:160;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;51798:923;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;;;;;;;:::i;:::-;;;;;;;;41757:47;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;50855:164;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;51668:122;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;50493:132;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;44437:252;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;49476:592;;;:::i;:::-;;42661:598;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;41818:50;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;50109:218;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;44847:287;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;41698:45;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;45142:162;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;51301:359;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;44289:140;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;50335:150;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;47231:1524;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;50684:163;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;42076:577;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;44697:142;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;41589:42;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;51157:136;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;43498:130;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;43636:219;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;43267:223;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;48765:703;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;43863:128;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;43999:282;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;42028:39;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;41638:46;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;45312:284;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;52729:892;52811:23;52836:24;52873:41;52917:32;:30;:32::i;:::-;52873:76;;52960:17;52980:35;53008:6;52980:23;52992:2;:10;;;52980:7;:11;;:23;;;;:::i;:::-;:27;;:35;;;;:::i;:::-;52960:55;;53026:19;53048:78;53095:30;:28;:30::i;:::-;53048;:28;:30::i;:::-;:42;;;:46;;:78;;;;:::i;:::-;53026:100;;53162:2;:9;;:16;;;;53148:31;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;53139:40;;53214:2;:9;;:16;;;;53200:31;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;53190:41;;53248:9;53244:334;53263:2;:9;;:16;;;;53259:1;:20;53244:334;;;53302:12;53317:2;:9;;53327:1;53317:12;;;;;;;;;;;;;;;;;;;;;;;;;53302:27;;53344:20;53367:23;53383:5;53367:7;:23::i;:::-;53344:46;;53405:19;53427:57;53472:11;53427:40;53444:22;53456:9;53444:7;:11;;:22;;;;:::i;:::-;53427:12;:16;;:40;;;;:::i;:::-;:44;;:57;;;;:::i;:::-;53405:79;;53521:5;53501:6;53508:1;53501:9;;;;;;;;;;;;;:26;;;;;;;;;;;53555:11;53542:7;53550:1;53542:10;;;;;;;;;;;;;:24;;;;;53244:334;;;53281:4;;;;;;;53244:334;;;;53590:23;;;52729:892;;;:::o;45774:1393::-;15119:47;15169:39;:37;:39::i;:::-;15119:89;;15215:1;:13;;;:15;;;;;;;;;;;;;15237:17;15257:1;:13;;;15237:33;;45857:4:::1;:12;;;:14;;;;;;;;;;;;;;;;;;;;;;;;;;;::::0;::::1;;;;;;;;;;;;::::0;::::1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;45856:15;45848:39;;;;;;;;;;;;:::i;:::-;;;;;;;;;45898:32;:30;:32::i;:::-;45941:41;45985:32;:30;:32::i;:::-;45941:76;;46028:19;46050:30;:28;:30::i;:::-;:42;;;46028:64;;46139:4;:11;;;:13;;;;;;;;;;;;;;;;;;;;;;;;;;;::::0;::::1;;;;;;;;;;;;::::0;::::1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;46111:24;46127:7;46111:11;:15;;:24;;;;:::i;:::-;:41;;46103:74;;;;;;;;;;;;:::i;:::-;;;;;;;;;46190:17;46210:36;46239:6;46210:24;46222:2;:11;;;46210:7;:11;;:24;;;;:::i;:::-;:28;;:36;;;;:::i;:::-;46190:56;;46263:9;46259:339;46278:2;:9;;:16;;;;46274:1;:20;46259:339;;;46317:12;46332:2;:9;;46342:1;46332:12;;;;;;;;;;;;;;;;;;;;;;;;;46317:27;;46359:19;46381:68;46437:11;46381:51;46409:22;46421:9;46409:7;:11;;:22;;;;:::i;:::-;46381:23;46397:5;46381:7;:23::i;:::-;:27;;:51;;;;:::i;:::-;:55;;:68;;;;:::i;:::-;46359:90;;46487:1;46472:11;:16;;46464:45;;;;;;;;;;;;:::i;:::-;;;;;;;;;46524:62;46547:10;46567:4;46574:11;46524:5;:22;;;;:62;;;;;;:::i;:::-;46259:339;;46296:4;;;;;;;46259:339;;;;46714:1;46701:9;:14;;:63;;;;;46763:1;46732:2;:27;;;:32;;46701:63;:111;;;;;46810:1;46781:31;;:2;:17;;;;;;;;;;;;:31;;;;46701:111;46684:382;;;46839:27;46869:54;46916:6;46869:42;46883:2;:27;;;46869:9;:13;;:42;;;;:::i;:::-;:46;;:54;;;;:::i;:::-;46839:84;;46964:1;46941:19;:24;46938:117;;46986:53;47000:2;:17;;;;;;;;;;;;47019:19;46986:13;:53::i;:::-;46938:117;46684:382;;47078:34;47092:10;47104:7;47078:13;:34::i;:::-;47139:10;47128:31;;;47151:7;47128:31;;;;;;:::i;:::-;;;;;;;;15277:1;;;15314::::0;:13;;;15301:9;:26;15285:110;;;;;;;;;;;;:::i;:::-;;;;;;;;;45774:1393;;;:::o;45604:160::-;45673:7;45700:32;:30;:32::i;:::-;:56;;;45693:63;;45604:160;:::o;51798:923::-;51876:23;51901:24;51938:41;51982:32;:30;:32::i;:::-;51938:76;;52025:19;52047:78;52094:30;:28;:30::i;:::-;52047;:28;:30::i;:::-;:42;;;:46;;:78;;;;:::i;:::-;52025:100;;52161:2;:9;;:16;;;;52147:31;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;52138:40;;52213:2;:9;;:16;;;;52199:31;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;52189:41;;52247:9;52243:435;52262:2;:9;;:16;;;;52258:1;:20;52243:435;;;52301:12;52316:2;:9;;52326:1;52316:12;;;;;;;;;;;;;;;;;;;;;;;;;52301:27;;52343:20;52366:23;52382:5;52366:7;:23::i;:::-;52343:46;;52404:19;52426:42;52456:11;52426:25;52443:7;52426:12;:16;;:25;;;;:::i;:::-;:29;;:42;;;;:::i;:::-;52404:64;;52527:57;52543:40;52576:6;52543:28;52559:2;:11;;;52543;:15;;:28;;;;:::i;:::-;:32;;:40;;;;:::i;:::-;52527:11;:15;;:57;;;;:::i;:::-;52513:71;;52621:5;52601:6;52608:1;52601:9;;;;;;;;;;;;;:26;;;;;;;;;;;52655:11;52642:7;52650:1;52642:10;;;;;;;;;;;;;:24;;;;;52243:435;;;52280:4;;;;;;;52243:435;;;;52690:23;;51798:923;;;:::o;41757:47::-;41798:6;41757:47;:::o;50855:164::-;14342:27;:25;:27::i;:::-;:41;;;;;;;;;;;;14328:55;;:10;:55;;;:99;;;;14422:4;14400:27;;:10;:27;;;14328:99;14306:147;;;;;;;;;;;;:::i;:::-;;;;;;;;;50973:7:::1;50931:32;:30;:32::i;:::-;:39;;:49;;;;50996:15;51003:7;50996:15;;;;;;:::i;:::-;;;;;;;;50855:164:::0;:::o;51668:122::-;51717:7;51743:32;:30;:32::i;:::-;:39;;;51736:46;;51668:122;:::o;50493:132::-;50548:7;50575:32;:30;:32::i;:::-;:42;;;50568:49;;50493:132;:::o;44437:252::-;14342:27;:25;:27::i;:::-;:41;;;;;;;;;;;;14328:55;;:10;:55;;;:99;;;;14422:4;14400:27;;:10;:27;;;14328:99;14306:147;;;;;;;;;;;;:::i;:::-;;;;;;;;;44529:32:::1;:30;:32::i;:::-;44622:12;44572:32;:30;:32::i;:::-;:47;;;:62;;;;;;;;;;;;;;;;;;44668:12;44650:31;;;;;;;;;;;;44437:252:::0;:::o;49476:592::-;49545:22;49570:30;:28;:30::i;:::-;49545:55;;49611:41;49655:32;:30;:32::i;:::-;49611:76;;49730:15;49700:2;:27;;:45;;;;49929:1;49911:14;:19;49894:123;;49957:48;49971:2;:17;;;;;;;;;;;;49990:14;49957:13;:48::i;:::-;49894:123;50034:26;50045:14;50034:26;;;;;;:::i;:::-;;;;;;;;49476:592;;:::o;42661:598::-;14342:27;:25;:27::i;:::-;:41;;;;;;;;;;;;14328:55;;:10;:55;;;:99;;;;14422:4;14400:27;;:10;:27;;;14328:99;14306:147;;;;;;;;;;;;:::i;:::-;;;;;;;;;42741:41:::1;42785:32;:30;:32::i;:::-;42741:76;;42838:2;:9;;:17;42848:6;42838:17;;;;;;;;;;;;;;;;;;;;;;;;;42830:47;;;;;;;;;;;;:::i;:::-;;;;;;;;;42910:5;42890:2;:9;;:17;42900:6;42890:17;;;;;;;;;;;;;;;;:25;;;;;;;;;;;;;;;;;;42968:9;42964:288;42983:2;:9;;:16;;;;42979:1;:20;42964:288;;;43050:6;43025:31;;43033:2;:9;;43043:1;43033:12;;;;;;;;;;;;;;;;;;;;;;;;;43025:31;;;43022:219;;;43092:2;:9;;43121:1;43102:2;:9;;:16;;;;:20;43092:31;;;;;;;;;;;;;;;;;;;;;;;;;43077:2;:9;;43087:1;43077:12;;;;;;;;;;;;;;;;:46;;;;;;;;;;;;;;;;;;43142:2;:9;;:15;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;43194:6;43181:20;;;;;;;;;;;;43220:5;;43022:219;43001:4;;;;;;;42964:288;;;;14464:1;42661:598:::0;:::o;41818:50::-;41860:8;41818:50;:::o;50109:218::-;50159:4;50176:41;50220:32;:30;:32::i;:::-;50176:76;;50286:1;50270:2;:12;;;:17;:49;;;;50307:12;50291:2;:12;;;:28;;50270:49;50263:56;;;50109:218;:::o;44847:287::-;14342:27;:25;:27::i;:::-;:41;;;;;;;;;;;;14328:55;;:10;:55;;;:99;;;;14422:4;14400:27;;:10;:27;;;14328:99;14306:147;;;;;;;;;;;;:::i;:::-;;;;;;;;;41860:8:::1;44951:6;:25;;44943:55;;;;;;;;;;;;:::i;:::-;;;;;;;;;45069:6;45009:32;:30;:32::i;:::-;:57;;:66;;;;45091:35;45119:6;45091:35;;;;;;:::i;:::-;;;;;;;;44847:287:::0;:::o;41698:45::-;41737:6;41698:45;:::o;45142:162::-;45212:7;45239:32;:30;:32::i;:::-;:57;;;45232:64;;45142:162;:::o;51301:359::-;51354:16;51383:22;51408:32;:30;:32::i;:::-;:39;;51383:64;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;51458:23;51498:6;:13;51484:28;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;51458:54;;51529:9;51525:101;51548:6;:13;51544:1;:17;51525:101;;;51604:6;51611:1;51604:9;;;;;;;;;;;;;;51584:6;51591:1;51584:9;;;;;;;;;;;;;:30;;;;;;;;;;;51563:4;;;;;;;51525:101;;;;51645:6;51638:14;;;;51301:359;:::o;44289:140::-;44348:7;44375:32;:30;:32::i;:::-;:46;;;44368:53;;44289:140;:::o;50335:150::-;50406:4;50430:32;:30;:32::i;:::-;:39;;:47;50470:6;50430:47;;;;;;;;;;;;;;;;;;;;;;;;;50423:54;;50335:150;;;:::o;47231:1524::-;15119:47;15169:39;:37;:39::i;:::-;15119:89;;15215:1;:13;;;:15;;;;;;;;;;;;;15237:17;15257:1;:13;;;15237:33;;47322:4:::1;:12;;;:14;;;;;;;;;;;;;;;;;;;;;;;;;;;::::0;::::1;;;;;;;;;;;;::::0;::::1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;47321:15;47313:39;;;;;;;;;;;;:::i;:::-;;;;;;;;;47363:32;:30;:32::i;:::-;47406:41;47450:32;:30;:32::i;:::-;47406:76;;47493:19;47515:30;:28;:30::i;:::-;:42;;;47493:64;;47570:17;47590:35;47618:6;47590:23;47602:2;:10;;;47590:7;:11;;:23;;;;:::i;:::-;:27;;:35;;;;:::i;:::-;47570:55;;47642:9;47638:461;47657:2;:9;;:16;;;;47653:1;:20;47638:461;;;47696:12;47711:2;:9;;47721:1;47711:12;;;;;;;;;;;;;;;;;;;;;;;;;47696:27;;47738:20;47761:23;47777:5;47761:7;:23::i;:::-;47738:46;;47858:19;47880:57;47925:11;47880:40;47897:22;47909:9;47897:7;:11;;:22;;;;:::i;:::-;47880:12;:16;;:40;;;;:::i;:::-;:44;;:57;;;;:::i;:::-;47858:79;;41626:5;47960:29;47977:11;47960:12;:16;;:29;;;;:::i;:::-;:43;;47952:77;;;;;;;;;;;;:::i;:::-;;;;;;;;;48044:43;48063:10;48075:11;48044:5;:18;;;;:43;;;;;:::i;:::-;47638:461;;;47675:4;;;;;;;47638:461;;;;48216:1;48203:9;:14;;:62;;;;;48264:1;48234:2;:26;;;:31;;48203:62;:110;;;;;48311:1;48282:31;;:2;:17;;;;;;;;;;;;:31;;;;48203:110;48186:380;;;48340:27;48370:53;48416:6;48370:41;48384:2;:26;;;48370:9;:13;;:41;;;;:::i;:::-;:45;;:53;;;;:::i;:::-;48340:83;;48464:1;48441:19;:24;48438:117;;48486:53;48500:2;:17;;;;;;;;;;;;48519:19;48486:13;:53::i;:::-;48438:117;48186:380;;41626:5;48586:24;48602:7;48586:11;:15;;:24;;;;:::i;:::-;:38;;48578:77;;;;;;;;;;;;:::i;:::-;;;;;;;;;48666:34;48680:10;48692:7;48666:13;:34::i;:::-;48727:10;48716:31;;;48739:7;48716:31;;;;;;:::i;:::-;;;;;;;;15277:1;;;15314::::0;:13;;;15301:9;:26;15285:110;;;;;;;;;;;;:::i;:::-;;;;;;;;;47231:1524;;;:::o;50684:163::-;14342:27;:25;:27::i;:::-;:41;;;;;;;;;;;;14328:55;;:10;:55;;;:99;;;;14422:4;14400:27;;:10;:27;;;14328:99;14306:147;;;;;;;;;;;;:::i;:::-;;;;;;;;;50804:5:::1;50759:32;:30;:32::i;:::-;:42;;:50;;;;50825:14;50833:5;50825:14;;;;;;:::i;:::-;;;;;;;;50684:163:::0;:::o;42076:577::-;14342:27;:25;:27::i;:::-;:41;;;;;;;;;;;;14328:55;;:10;:55;;;:99;;;;14422:4;14400:27;;:10;:27;;;14328:99;14306:147;;;;;;;;;;;;:::i;:::-;;;;;;;;;42153:41:::1;42197:32;:30;:32::i;:::-;42153:76;;42249:2;:9;;:17;42259:6;42249:17;;;;;;;;;;;;;;;;;;;;;;;;;42248:18;42240:52;;;;;;;;;;;;:::i;:::-;;;;;;;;;42065:2;42311;:9;;:16;;;;:29;42303:61;;;;;;;;;;;;:::i;:::-;;;;;;;;;41626:5;42480:15;42488:6;42480:7;:15::i;:::-;:29;;42472:59;;;;;;;;;;;;:::i;:::-;;;;;;;;;42564:4;42544:2;:9;;:17;42554:6;42544:17;;;;;;;;;;;;;;;;:24;;;;;;;;;;;;;;;;;;42579:2;:9;;42601:6;42579:30;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;42638:6;42627:18;;;;;;;;;;;;14464:1;42076:577:::0;:::o;44697:142::-;44757:7;44784:32;:30;:32::i;:::-;:47;;;;;;;;;;;;44777:54;;44697:142;:::o;41589:42::-;41626:5;41589:42;:::o;51157:136::-;51219:7;51253:6;51246:24;;;51279:4;51246:39;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;51239:46;;51157:136;;;:::o;43498:130::-;43552:7;43579:32;:30;:32::i;:::-;:41;;;43572:48;;43498:130;:::o;43636:219::-;14342:27;:25;:27::i;:::-;:41;;;;;;;;;;;;14328:55;;:10;:55;;;:99;;;;14422:4;14400:27;;:10;:27;;;14328:99;14306:147;;;;;;;;;;;;:::i;:::-;;;;;;;;;41737:6:::1;43721:4;:20;;43713:44;;;;;;;;;;;;:::i;:::-;;;;;;;;;43811:4;43768:32;:30;:32::i;:::-;:40;;:47;;;;43831:16;43842:4;43831:16;;;;;;:::i;:::-;;;;;;;;43636:219:::0;:::o;43267:223::-;14342:27;:25;:27::i;:::-;:41;;;;;;;;;;;;14328:55;;:10;:55;;;:99;;;;14422:4;14400:27;;:10;:27;;;14328:99;14306:147;;;;;;;;;;;;:::i;:::-;;;;;;;;;41678:6:::1;43353:4;:21;;43345:45;;;;;;;;;;;;:::i;:::-;;;;;;;;;43445:4;43401:32;:30;:32::i;:::-;:41;;:48;;;;43465:17;43477:4;43465:17;;;;;;:::i;:::-;;;;;;;;43267:223:::0;:::o;48765:703::-;48834:7;48854:41;48898:32;:30;:32::i;:::-;48854:76;;48941:19;48963:30;:28;:30::i;:::-;:42;;;48941:64;;49018:22;49043:2;:27;;;49018:52;;49081:21;49105:2;:16;;;49081:40;;49168:1;49151:13;:18;:66;;;;49215:1;49186:31;;:2;:17;;;;;;;;;;;;:31;;;49151:66;:102;;;;49252:1;49234:14;:19;49151:102;49134:166;;;49287:1;49280:8;;;;;;;;49134:166;49312:18;49333:35;49353:14;49333:15;:19;;:35;;;;:::i;:::-;49312:56;;49388:72;49451:8;49388:58;49435:10;49388:42;49423:6;49388:30;49404:13;49388:11;:15;;:30;;;;:::i;:::-;:34;;:42;;;;:::i;:::-;:46;;:58;;;;:::i;:::-;:62;;:72;;;;:::i;:::-;49381:79;;;;;;;48765:703;;:::o;43863:128::-;43916:7;43943:32;:30;:32::i;:::-;:40;;;43936:47;;43863:128;:::o;43999:282::-;14342:27;:25;:27::i;:::-;:41;;;;;;;;;;;;14328:55;;:10;:55;;;:99;;;;14422:4;14400:27;;:10;:27;;;14328:99;14306:147;;;;;;;;;;;;:::i;:::-;;;;;;;;;44082:32:::1;:30;:32::i;:::-;41798:6;44133:4;:22;;44125:46;;;;;;;;;;;;:::i;:::-;;;;;;;;;44231:4;44182:32;:30;:32::i;:::-;:46;;:53;;;;44251:22;44268:4;44251:22;;;;;;:::i;:::-;;;;;;;;43999:282:::0;:::o;42028:39::-;42065:2;42028:39;:::o;41638:46::-;41678:6;41638:46;:::o;45312:284::-;14342:27;:25;:27::i;:::-;:41;;;;;;;;;;;;14328:55;;:10;:55;;;:99;;;;14422:4;14400:27;;:10;:27;;;14328:99;14306:147;;;;;;;;;;;;:::i;:::-;;;;;;;;;41860:8:::1;45415:6;:25;;45407:55;;;;;;;;;;;;:::i;:::-;;;;;;;;;45532:6;45473:32;:30;:32::i;:::-;:56;;:65;;;;45554:34;45581:6;45554:34;;;;;;:::i;:::-;;;;;;;;45312:284:::0;:::o;662:179::-;710:24;743:16;143:54;743:42;;821:8;810:19;;801:35;;:::o;38238:471::-;38296:7;38546:1;38541;:6;38537:47;;;38571:1;38564:8;;;;38537:47;38596:9;38612:1;38608;:5;38596:17;;38641:1;38636;38632;:5;;;;;;:10;38624:56;;;;;;;;;;;;:::i;:::-;;;;;;;;;38700:1;38693:8;;;38238:471;;;;;:::o;39185:132::-;39243:7;39270:39;39274:1;39277;39270:39;;;;;;;;;;;;;;;;;:3;:39::i;:::-;39263:46;;39185:132;;;;:::o;16797:177::-;16844:23;16876:16;16499:87;16876:42;;16954:8;16943:19;;16934:35;;:::o;36884:181::-;36942:7;36962:9;36978:1;36974;:5;36962:17;;37003:1;36998;:6;;36990:46;;;;;;;;;;;;:::i;:::-;;;;;;;;;37056:1;37049:8;;;36884:181;;;;:::o;37348:136::-;37406:7;37433:43;37437:1;37440;37433:43;;;;;;;;;;;;;;;;;:3;:43::i;:::-;37426:50;;37348:136;;;;:::o;14761:172::-;14805:20;14834:16;14644:55;14834:43;;14913:8;14902:19;;14893:35;;:::o;33089:205::-;33190:96;33210:5;33240:27;;;33269:4;33275:2;33279:5;33217:68;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;33190:19;:96::i;:::-;33089:205;;;;:::o;15698:349::-;15781:1;15766:17;;:3;:17;;;;15758:48;;;;;;;;;;;;:::i;:::-;;;;;;;;;15815:39;15857:30;:28;:30::i;:::-;15815:72;;15915:29;15936:7;15915:2;:11;;:16;15927:3;15915:16;;;;;;;;;;;;;;;;:20;;:29;;;;:::i;:::-;15896:2;:11;;:16;15908:3;15896:16;;;;;;;;;;;;;;;:48;;;;15968:27;15987:7;15968:2;:14;;;:18;;:27;;;;:::i;:::-;15951:2;:14;;:44;;;;16028:3;16007:34;;16024:1;16007:34;;;16033:7;16007:34;;;;;;:::i;:::-;;;;;;;;15698:349;;;:::o;3410:202::-;3459:25;3497:16;2542:45;3497:43;;3586:8;3575:19;;3560:45;;:::o;32904:177::-;32987:86;33007:5;33037:23;;;33062:2;33066:5;33014:58;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;32987:19;:86::i;:::-;32904:177;;;:::o;16053:300::-;16115:39;16157:30;:28;:30::i;:::-;16115:72;;16217:31;16240:7;16217:2;:11;;:18;16229:5;16217:18;;;;;;;;;;;;;;;;:22;;:31;;;;:::i;:::-;16196:2;:11;;:18;16208:5;16196:18;;;;;;;;;;;;;;;:52;;;;16272:27;16291:7;16272:2;:14;;;:18;;:27;;;;:::i;:::-;16255:2;:14;;:44;;;;16335:1;16311:36;;16320:5;16311:36;;;16339:7;16311:36;;;;;;:::i;:::-;;;;;;;;16053:300;;;:::o;39813:278::-;39899:7;39931:1;39927;:5;39934:12;39919:28;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;39958:9;39974:1;39970;:5;;;;;;39958:17;;40082:1;40075:8;;;39813:278;;;;;:::o;37787:192::-;37873:7;37906:1;37901;:6;;37909:12;37893:29;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;37933:9;37949:1;37945;:5;37933:17;;37970:1;37963:8;;;37787:192;;;;;:::o;35209:761::-;35633:23;35659:69;35687:4;35659:69;;;;;;;;;;;;;;;;;35667:5;35659:27;;;;:69;;;;;:::i;:::-;35633:95;;35763:1;35743:10;:17;:21;35739:224;;;35885:10;35874:30;;;;;;;;;;;;:::i;:::-;35866:85;;;;;;;;;;;;:::i;:::-;;;;;;;;;35739:224;35209:761;;;:::o;27132:196::-;27235:12;27267:53;27290:6;27298:4;27304:1;27307:12;27267:22;:53::i;:::-;27260:60;;27132:196;;;;;:::o;28509:979::-;28639:12;28672:18;28683:6;28672:10;:18::i;:::-;28664:60;;;;;;;;;;;;:::i;:::-;;;;;;;;;28798:12;28812:23;28839:6;:11;;28859:8;28870:4;28839:36;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;28797:78;;;;28890:7;28886:595;;;28921:10;28914:17;;;;;;28886:595;29055:1;29035:10;:17;:21;29031:439;;;29298:10;29292:17;29359:15;29346:10;29342:2;29338:19;29331:44;29246:148;29441:12;29434:20;;;;;;;;;;;:::i;:::-;;;;;;;;28509:979;;;;;;;:::o;24017:619::-;24077:4;24339:16;24366:19;24388:66;24366:88;;;;24557:7;24545:20;24533:32;;24597:11;24585:8;:23;;:42;;;;;24624:3;24612:15;;:8;:15;;24585:42;24577:51;;;;24017:619;;;:::o;5:130:-1:-;;85:6;72:20;63:29;;97:33;124:5;97:33;:::i;:::-;57:78;;;;:::o;142:128::-;;223:6;217:13;208:22;;235:30;259:5;235:30;:::i;:::-;202:68;;;;:::o;277:130::-;;357:6;344:20;335:29;;369:33;396:5;369:33;:::i;:::-;329:78;;;;:::o;414:134::-;;498:6;492:13;483:22;;510:33;537:5;510:33;:::i;:::-;477:71;;;;:::o;555:241::-;;659:2;647:9;638:7;634:23;630:32;627:2;;;675:1;672;665:12;627:2;710:1;727:53;772:7;763:6;752:9;748:22;727:53;:::i;:::-;717:63;;689:97;621:175;;;;:::o;803:257::-;;915:2;903:9;894:7;890:23;886:32;883:2;;;931:1;928;921:12;883:2;966:1;983:61;1036:7;1027:6;1016:9;1012:22;983:61;:::i;:::-;973:71;;945:105;877:183;;;;:::o;1067:241::-;;1171:2;1159:9;1150:7;1146:23;1142:32;1139:2;;;1187:1;1184;1177:12;1139:2;1222:1;1239:53;1284:7;1275:6;1264:9;1260:22;1239:53;:::i;:::-;1229:63;;1201:97;1133:175;;;;:::o;1315:263::-;;1430:2;1418:9;1409:7;1405:23;1401:32;1398:2;;;1446:1;1443;1436:12;1398:2;1481:1;1498:64;1554:7;1545:6;1534:9;1530:22;1498:64;:::i;:::-;1488:74;;1460:108;1392:186;;;;:::o;1586:173::-;;1673:46;1715:3;1707:6;1673:46;:::i;:::-;1748:4;1743:3;1739:14;1725:28;;1666:93;;;;:::o;1768:173::-;;1855:46;1897:3;1889:6;1855:46;:::i;:::-;1930:4;1925:3;1921:14;1907:28;;1848:93;;;;:::o;1949:103::-;2022:24;2040:5;2022:24;:::i;:::-;2017:3;2010:37;2004:48;;:::o;2059:113::-;2142:24;2160:5;2142:24;:::i;:::-;2137:3;2130:37;2124:48;;:::o;2210:690::-;;2355:54;2403:5;2355:54;:::i;:::-;2422:86;2501:6;2496:3;2422:86;:::i;:::-;2415:93;;2529:56;2579:5;2529:56;:::i;:::-;2605:7;2633:1;2618:260;2643:6;2640:1;2637:13;2618:260;;;2710:6;2704:13;2731:63;2790:3;2775:13;2731:63;:::i;:::-;2724:70;;2811:60;2864:6;2811:60;:::i;:::-;2801:70;;2675:203;2665:1;2662;2658:9;2653:14;;2618:260;;;2622:14;2891:3;2884:10;;2334:566;;;;;;;:::o;2939:690::-;;3084:54;3132:5;3084:54;:::i;:::-;3151:86;3230:6;3225:3;3151:86;:::i;:::-;3144:93;;3258:56;3308:5;3258:56;:::i;:::-;3334:7;3362:1;3347:260;3372:6;3369:1;3366:13;3347:260;;;3439:6;3433:13;3460:63;3519:3;3504:13;3460:63;:::i;:::-;3453:70;;3540:60;3593:6;3540:60;:::i;:::-;3530:70;;3404:203;3394:1;3391;3387:9;3382:14;;3347:260;;;3351:14;3620:3;3613:10;;3063:566;;;;;;;:::o;3637:104::-;3714:21;3729:5;3714:21;:::i;:::-;3709:3;3702:34;3696:45;;:::o;3748:356::-;;3876:38;3908:5;3876:38;:::i;:::-;3926:88;4007:6;4002:3;3926:88;:::i;:::-;3919:95;;4019:52;4064:6;4059:3;4052:4;4045:5;4041:16;4019:52;:::i;:::-;4092:6;4087:3;4083:16;4076:23;;3856:248;;;;;:::o;4111:347::-;;4223:39;4256:5;4223:39;:::i;:::-;4274:71;4338:6;4333:3;4274:71;:::i;:::-;4267:78;;4350:52;4395:6;4390:3;4383:4;4376:5;4372:16;4350:52;:::i;:::-;4423:29;4445:6;4423:29;:::i;:::-;4418:3;4414:39;4407:46;;4203:255;;;;;:::o;4466:321::-;;4626:67;4690:2;4685:3;4626:67;:::i;:::-;4619:74;;4726:23;4722:1;4717:3;4713:11;4706:44;4778:2;4773:3;4769:12;4762:19;;4612:175;;;:::o;4796:316::-;;4956:67;5020:2;5015:3;4956:67;:::i;:::-;4949:74;;5056:18;5052:1;5047:3;5043:11;5036:39;5103:2;5098:3;5094:12;5087:19;;4942:170;;;:::o;5121:320::-;;5281:67;5345:2;5340:3;5281:67;:::i;:::-;5274:74;;5381:22;5377:1;5372:3;5368:11;5361:43;5432:2;5427:3;5423:12;5416:19;;5267:174;;;:::o;5450:327::-;;5610:67;5674:2;5669:3;5610:67;:::i;:::-;5603:74;;5710:29;5706:1;5701:3;5697:11;5690:50;5768:2;5763:3;5759:12;5752:19;;5596:181;;;:::o;5786:311::-;;5946:67;6010:2;6005:3;5946:67;:::i;:::-;5939:74;;6046:13;6042:1;6037:3;6033:11;6026:34;6088:2;6083:3;6079:12;6072:19;;5932:165;;;:::o;6106:319::-;;6266:67;6330:2;6325:3;6266:67;:::i;:::-;6259:74;;6366:21;6362:1;6357:3;6353:11;6346:42;6416:2;6411:3;6407:12;6400:19;;6252:173;;;:::o;6434:318::-;;6594:67;6658:2;6653:3;6594:67;:::i;:::-;6587:74;;6694:20;6690:1;6685:3;6681:11;6674:41;6743:2;6738:3;6734:12;6727:19;;6580:172;;;:::o;6761:311::-;;6921:67;6985:2;6980:3;6921:67;:::i;:::-;6914:74;;7021:13;7017:1;7012:3;7008:11;7001:34;7063:2;7058:3;7054:12;7047:19;;6907:165;;;:::o;7081:370::-;;7241:67;7305:2;7300:3;7241:67;:::i;:::-;7234:74;;7341:34;7337:1;7332:3;7328:11;7321:55;7410:3;7405:2;7400:3;7396:12;7389:25;7442:2;7437:3;7433:12;7426:19;;7227:224;;;:::o;7460:311::-;;7620:67;7684:2;7679:3;7620:67;:::i;:::-;7613:74;;7720:13;7716:1;7711:3;7707:11;7700:34;7762:2;7757:3;7753:12;7746:19;;7606:165;;;:::o;7780:321::-;;7940:67;8004:2;7999:3;7940:67;:::i;:::-;7933:74;;8040:23;8036:1;8031:3;8027:11;8020:44;8092:2;8087:3;8083:12;8076:19;;7926:175;;;:::o;8110:317::-;;8270:67;8334:2;8329:3;8270:67;:::i;:::-;8263:74;;8370:19;8366:1;8361:3;8357:11;8350:40;8418:2;8413:3;8409:12;8402:19;;8256:171;;;:::o;8436:329::-;;8596:67;8660:2;8655:3;8596:67;:::i;:::-;8589:74;;8696:31;8692:1;8687:3;8683:11;8676:52;8756:2;8751:3;8747:12;8740:19;;8582:183;;;:::o;8774:326::-;;8934:67;8998:2;8993:3;8934:67;:::i;:::-;8927:74;;9034:28;9030:1;9025:3;9021:11;9014:49;9091:2;9086:3;9082:12;9075:19;;8920:180;;;:::o;9109:317::-;;9269:67;9333:2;9328:3;9269:67;:::i;:::-;9262:74;;9369:19;9365:1;9360:3;9356:11;9349:40;9417:2;9412:3;9408:12;9401:19;;9255:171;;;:::o;9435:379::-;;9595:67;9659:2;9654:3;9595:67;:::i;:::-;9588:74;;9695:34;9691:1;9686:3;9682:11;9675:55;9764:12;9759:2;9754:3;9750:12;9743:34;9805:2;9800:3;9796:12;9789:19;;9581:233;;;:::o;9823:387::-;;9983:67;10047:2;10042:3;9983:67;:::i;:::-;9976:74;;10083:34;10079:1;10074:3;10070:11;10063:55;10152:20;10147:2;10142:3;10138:12;10131:42;10201:2;10196:3;10192:12;10185:19;;9969:241;;;:::o;10219:317::-;;10379:67;10443:2;10438:3;10379:67;:::i;:::-;10372:74;;10479:19;10475:1;10470:3;10466:11;10459:40;10527:2;10522:3;10518:12;10511:19;;10365:171;;;:::o;10544:103::-;10617:24;10635:5;10617:24;:::i;:::-;10612:3;10605:37;10599:48;;:::o;10654:113::-;10737:24;10755:5;10737:24;:::i;:::-;10732:3;10725:37;10719:48;;:::o;10774:271::-;;10927:93;11016:3;11007:6;10927:93;:::i;:::-;10920:100;;11037:3;11030:10;;10908:137;;;;:::o;11052:222::-;;11179:2;11168:9;11164:18;11156:26;;11193:71;11261:1;11250:9;11246:17;11237:6;11193:71;:::i;:::-;11150:124;;;;:::o;11281:444::-;;11464:2;11453:9;11449:18;11441:26;;11478:71;11546:1;11535:9;11531:17;11522:6;11478:71;:::i;:::-;11560:72;11628:2;11617:9;11613:18;11604:6;11560:72;:::i;:::-;11643;11711:2;11700:9;11696:18;11687:6;11643:72;:::i;:::-;11435:290;;;;;;:::o;11732:333::-;;11887:2;11876:9;11872:18;11864:26;;11901:71;11969:1;11958:9;11954:17;11945:6;11901:71;:::i;:::-;11983:72;12051:2;12040:9;12036:18;12027:6;11983:72;:::i;:::-;11858:207;;;;;:::o;12072:370::-;;12249:2;12238:9;12234:18;12226:26;;12299:9;12293:4;12289:20;12285:1;12274:9;12270:17;12263:47;12324:108;12427:4;12418:6;12324:108;:::i;:::-;12316:116;;12220:222;;;;:::o;12449:629::-;;12704:2;12693:9;12689:18;12681:26;;12754:9;12748:4;12744:20;12740:1;12729:9;12725:17;12718:47;12779:108;12882:4;12873:6;12779:108;:::i;:::-;12771:116;;12935:9;12929:4;12925:20;12920:2;12909:9;12905:18;12898:48;12960:108;13063:4;13054:6;12960:108;:::i;:::-;12952:116;;12675:403;;;;;:::o;13085:210::-;;13206:2;13195:9;13191:18;13183:26;;13220:65;13282:1;13271:9;13267:17;13258:6;13220:65;:::i;:::-;13177:118;;;;:::o;13302:310::-;;13449:2;13438:9;13434:18;13426:26;;13499:9;13493:4;13489:20;13485:1;13474:9;13470:17;13463:47;13524:78;13597:4;13588:6;13524:78;:::i;:::-;13516:86;;13420:192;;;;:::o;13619:416::-;;13819:2;13808:9;13804:18;13796:26;;13869:9;13863:4;13859:20;13855:1;13844:9;13840:17;13833:47;13894:131;14020:4;13894:131;:::i;:::-;13886:139;;13790:245;;;:::o;14042:416::-;;14242:2;14231:9;14227:18;14219:26;;14292:9;14286:4;14282:20;14278:1;14267:9;14263:17;14256:47;14317:131;14443:4;14317:131;:::i;:::-;14309:139;;14213:245;;;:::o;14465:416::-;;14665:2;14654:9;14650:18;14642:26;;14715:9;14709:4;14705:20;14701:1;14690:9;14686:17;14679:47;14740:131;14866:4;14740:131;:::i;:::-;14732:139;;14636:245;;;:::o;14888:416::-;;15088:2;15077:9;15073:18;15065:26;;15138:9;15132:4;15128:20;15124:1;15113:9;15109:17;15102:47;15163:131;15289:4;15163:131;:::i;:::-;15155:139;;15059:245;;;:::o;15311:416::-;;15511:2;15500:9;15496:18;15488:26;;15561:9;15555:4;15551:20;15547:1;15536:9;15532:17;15525:47;15586:131;15712:4;15586:131;:::i;:::-;15578:139;;15482:245;;;:::o;15734:416::-;;15934:2;15923:9;15919:18;15911:26;;15984:9;15978:4;15974:20;15970:1;15959:9;15955:17;15948:47;16009:131;16135:4;16009:131;:::i;:::-;16001:139;;15905:245;;;:::o;16157:416::-;;16357:2;16346:9;16342:18;16334:26;;16407:9;16401:4;16397:20;16393:1;16382:9;16378:17;16371:47;16432:131;16558:4;16432:131;:::i;:::-;16424:139;;16328:245;;;:::o;16580:416::-;;16780:2;16769:9;16765:18;16757:26;;16830:9;16824:4;16820:20;16816:1;16805:9;16801:17;16794:47;16855:131;16981:4;16855:131;:::i;:::-;16847:139;;16751:245;;;:::o;17003:416::-;;17203:2;17192:9;17188:18;17180:26;;17253:9;17247:4;17243:20;17239:1;17228:9;17224:17;17217:47;17278:131;17404:4;17278:131;:::i;:::-;17270:139;;17174:245;;;:::o;17426:416::-;;17626:2;17615:9;17611:18;17603:26;;17676:9;17670:4;17666:20;17662:1;17651:9;17647:17;17640:47;17701:131;17827:4;17701:131;:::i;:::-;17693:139;;17597:245;;;:::o;17849:416::-;;18049:2;18038:9;18034:18;18026:26;;18099:9;18093:4;18089:20;18085:1;18074:9;18070:17;18063:47;18124:131;18250:4;18124:131;:::i;:::-;18116:139;;18020:245;;;:::o;18272:416::-;;18472:2;18461:9;18457:18;18449:26;;18522:9;18516:4;18512:20;18508:1;18497:9;18493:17;18486:47;18547:131;18673:4;18547:131;:::i;:::-;18539:139;;18443:245;;;:::o;18695:416::-;;18895:2;18884:9;18880:18;18872:26;;18945:9;18939:4;18935:20;18931:1;18920:9;18916:17;18909:47;18970:131;19096:4;18970:131;:::i;:::-;18962:139;;18866:245;;;:::o;19118:416::-;;19318:2;19307:9;19303:18;19295:26;;19368:9;19362:4;19358:20;19354:1;19343:9;19339:17;19332:47;19393:131;19519:4;19393:131;:::i;:::-;19385:139;;19289:245;;;:::o;19541:416::-;;19741:2;19730:9;19726:18;19718:26;;19791:9;19785:4;19781:20;19777:1;19766:9;19762:17;19755:47;19816:131;19942:4;19816:131;:::i;:::-;19808:139;;19712:245;;;:::o;19964:416::-;;20164:2;20153:9;20149:18;20141:26;;20214:9;20208:4;20204:20;20200:1;20189:9;20185:17;20178:47;20239:131;20365:4;20239:131;:::i;:::-;20231:139;;20135:245;;;:::o;20387:416::-;;20587:2;20576:9;20572:18;20564:26;;20637:9;20631:4;20627:20;20623:1;20612:9;20608:17;20601:47;20662:131;20788:4;20662:131;:::i;:::-;20654:139;;20558:245;;;:::o;20810:416::-;;21010:2;20999:9;20995:18;20987:26;;21060:9;21054:4;21050:20;21046:1;21035:9;21031:17;21024:47;21085:131;21211:4;21085:131;:::i;:::-;21077:139;;20981:245;;;:::o;21233:222::-;;21360:2;21349:9;21345:18;21337:26;;21374:71;21442:1;21431:9;21427:17;21418:6;21374:71;:::i;:::-;21331:124;;;;:::o;21462:151::-;;21548:3;21540:11;;21586:4;21581:3;21577:14;21569:22;;21534:79;;;:::o;21620:151::-;;21706:3;21698:11;;21744:4;21739:3;21735:14;21727:22;;21692:79;;;:::o;21778:137::-;;21887:5;21881:12;21871:22;;21852:63;;;:::o;21922:137::-;;22031:5;22025:12;22015:22;;21996:63;;;:::o;22066:121::-;;22159:5;22153:12;22143:22;;22124:63;;;:::o;22194:122::-;;22288:5;22282:12;22272:22;;22253:63;;;:::o;22323:108::-;;22421:4;22416:3;22412:14;22404:22;;22398:33;;;:::o;22438:108::-;;22536:4;22531:3;22527:14;22519:22;;22513:33;;;:::o;22554:178::-;;22684:6;22679:3;22672:19;22721:4;22716:3;22712:14;22697:29;;22665:67;;;;:::o;22741:178::-;;22871:6;22866:3;22859:19;22908:4;22903:3;22899:14;22884:29;;22852:67;;;;:::o;22928:144::-;;23063:3;23048:18;;23041:31;;;;:::o;23081:163::-;;23196:6;23191:3;23184:19;23233:4;23228:3;23224:14;23209:29;;23177:67;;;;:::o;23252:91::-;;23314:24;23332:5;23314:24;:::i;:::-;23303:35;;23297:46;;;:::o;23350:85::-;;23423:5;23416:13;23409:21;23398:32;;23392:43;;;:::o;23442:121::-;;23515:42;23508:5;23504:54;23493:65;;23487:76;;;:::o;23570:72::-;;23632:5;23621:16;;23615:27;;;:::o;23650:268::-;23715:1;23722:101;23736:6;23733:1;23730:13;23722:101;;;23812:1;23807:3;23803:11;23797:18;23793:1;23788:3;23784:11;23777:39;23758:2;23755:1;23751:10;23746:15;;23722:101;;;23838:6;23835:1;23832:13;23829:2;;;23903:1;23894:6;23889:3;23885:16;23878:27;23829:2;23699:219;;;;:::o;23926:97::-;;24014:2;24010:7;24005:2;23998:5;23994:14;23990:28;23980:38;;23974:49;;;:::o;24031:117::-;24100:24;24118:5;24100:24;:::i;:::-;24093:5;24090:35;24080:2;;24139:1;24136;24129:12;24080:2;24074:74;:::o;24155:111::-;24221:21;24236:5;24221:21;:::i;:::-;24214:5;24211:32;24201:2;;24257:1;24254;24247:12;24201:2;24195:71;:::o;24273:117::-;24342:24;24360:5;24342:24;:::i;:::-;24335:5;24332:35;24322:2;;24381:1;24378;24371:12;24322:2;24316:74;:::o

Swarm Source

ipfs://719af08339555ff8d4aecbaeea4e16017e54385acfc1f5c255cd2d9d95ae1eb8
Block Transaction Gas Used Reward
Age Block Fee Address BC Fee Address Voting Power Jailed Incoming
Block Uncle Number Difficulty Gas Used Reward
Loading
Loading
Make sure to use the "Vote Down" button for any spammy posts, and the "Vote Up" for interesting conversations.