Contract 0x2Fe5E5D341cFFa606a5d9DA1B6B646a381B0f7ec 11

 
 
Txn Hash Method
Block
From
To
Value [Txn Fee]
0x51d8aa2586df314ee9509a42fa29972dd21a9df5c5398353335e3328a927ce46Post Price List338945362022-10-03 21:50:1432 secs ago0x491e59c255c790d4e3a53cec2632524088f1aaa4 IN  0x2fe5e5d341cffa606a5d9da1b6b646a381b0f7ec0 MATIC0.0041591 100.000000015
0x13fd1e12e12021a42182929aa26328593040d2c2a0d140bb26163e3a12865326Post Price338944892022-10-03 21:48:362 mins ago0x491e59c255c790d4e3a53cec2632524088f1aaa4 IN  0x2fe5e5d341cffa606a5d9da1b6b646a381b0f7ec0 MATIC0.0034196 100.000000012
0xfa5b15aebc8bec9e81b0988b8e497115e88a261be6a78a9232966d73161a6165Post Price List338944562022-10-03 21:47:263 mins ago0x491e59c255c790d4e3a53cec2632524088f1aaa4 IN  0x2fe5e5d341cffa606a5d9da1b6b646a381b0f7ec0 MATIC0.0047555 100.000000014
0xd18644ed3f7b7dad99f63a021f24bbc8336b440458f6c5559c620804f185ceb6Post Price338944202022-10-03 21:46:144 mins ago0x491e59c255c790d4e3a53cec2632524088f1aaa4 IN  0x2fe5e5d341cffa606a5d9da1b6b646a381b0f7ec0 MATIC0.0034184 100.000000015
0x912aa0a058bc5b7df6e74de7546df13ba3a3fdb07ca37344899bc5e04822c957Post Price List338944112022-10-03 21:45:564 mins ago0x491e59c255c790d4e3a53cec2632524088f1aaa4 IN  0x2fe5e5d341cffa606a5d9da1b6b646a381b0f7ec0 MATIC0.0047567 100.000000014
0xdc73053ca6641fbed19a52f8d89a7eecc1fa220431d2ebb6adee66c51584b057Post Price List338943822022-10-03 21:44:545 mins ago0x491e59c255c790d4e3a53cec2632524088f1aaa4 IN  0x2fe5e5d341cffa606a5d9da1b6b646a381b0f7ec0 MATIC0.0047555 100.00000001
0xa044e2fb79316a65821edebf96ba638e5e7cf573b95076c1e4eeab31d408c3daPost Price List338943682022-10-03 21:44:266 mins ago0x491e59c255c790d4e3a53cec2632524088f1aaa4 IN  0x2fe5e5d341cffa606a5d9da1b6b646a381b0f7ec0 MATIC0.0041543 100.000000012
0x94583fbcf757e43763b69261857292d667329d5f893ace985b88686ea745b872Post Price338943672022-10-03 21:44:246 mins ago0x491e59c255c790d4e3a53cec2632524088f1aaa4 IN  0x2fe5e5d341cffa606a5d9da1b6b646a381b0f7ec0 MATIC0.0034184 100.000000012
0xd18dff1ad8f9dc9b308638856ac208826788faeb4b24ea2e8a2efe71c3c672caPost Price338943632022-10-03 21:44:166 mins ago0x491e59c255c790d4e3a53cec2632524088f1aaa4 IN  0x2fe5e5d341cffa606a5d9da1b6b646a381b0f7ec0 MATIC0.0034244 100.000000011
0x1e5183d014975ce3545e8531c2b3aba05bfaec5c5ae69d63906c8ea110fa7e66Post Price338942762022-10-03 21:41:189 mins ago0x491e59c255c790d4e3a53cec2632524088f1aaa4 IN  0x2fe5e5d341cffa606a5d9da1b6b646a381b0f7ec0 MATIC0.0034184 100.000000018
0x371a0a5db8c848353e629881c45f179de6450c92552aacc4a1963d103dfad1e3Post Price338941472022-10-03 21:36:4314 mins ago0x491e59c255c790d4e3a53cec2632524088f1aaa4 IN  0x2fe5e5d341cffa606a5d9da1b6b646a381b0f7ec0 MATIC0.0034184 100.000000012
0x81205d5ed4564bb3afdf08de9eb3410db0830331abf33417a289d612e5561c65Post Price List338941362022-10-03 21:36:1714 mins ago0x491e59c255c790d4e3a53cec2632524088f1aaa4 IN  0x2fe5e5d341cffa606a5d9da1b6b646a381b0f7ec0 MATIC0.0047555 100.000000011
0xcf3edc06d476665087df5a4ac1ae5f0eae6a986d1cc89f6fe3f88b44da35c0fePost Price338940572022-10-03 21:33:3517 mins ago0x491e59c255c790d4e3a53cec2632524088f1aaa4 IN  0x2fe5e5d341cffa606a5d9da1b6b646a381b0f7ec0 MATIC0.0034184 100.000000011
0xc9ddf905f655d5fa680c7efd0913aaaf4bd5f4f3df826cee1c5b16050b9ae447Post Price List338940382022-10-03 21:32:5717 mins ago0x491e59c255c790d4e3a53cec2632524088f1aaa4 IN  0x2fe5e5d341cffa606a5d9da1b6b646a381b0f7ec0 MATIC0.0047567 100.00000001
0xe45e1f5efece15893e6ba89faa909860499dbcc30b4ce978c137d600ec63cbdcPost Price List338939062022-10-03 21:28:2522 mins ago0x491e59c255c790d4e3a53cec2632524088f1aaa4 IN  0x2fe5e5d341cffa606a5d9da1b6b646a381b0f7ec0 MATIC0.0041591 100.000000012
0xaed05bf1656400b1e8caae0cbbdec33e6a914f64338051fc33acba7e3fffe340Post Price List338938402022-10-03 21:26:0024 mins ago0x491e59c255c790d4e3a53cec2632524088f1aaa4 IN  0x2fe5e5d341cffa606a5d9da1b6b646a381b0f7ec0 MATIC0.0041591 100.000000013
0x198829d72220bcb60412d0a1555b8dee2cfd92d7a232e1602509cba9a85c9762Post Price338938122022-10-03 21:24:5125 mins ago0x491e59c255c790d4e3a53cec2632524088f1aaa4 IN  0x2fe5e5d341cffa606a5d9da1b6b646a381b0f7ec0 MATIC0.0034196 100.000000011
0x3b4e4b0c4c017969e08cbce0211ba2552cb9e67d3db252c01e0e322a4a700f3aPost Price List338936812022-10-03 21:20:2130 mins ago0x491e59c255c790d4e3a53cec2632524088f1aaa4 IN  0x2fe5e5d341cffa606a5d9da1b6b646a381b0f7ec0 MATIC0.0041603 100.000000013
0x8b0e1d7240f4368071150290a0fc8bf41b59b7d50412039f1f11a829306f94a1Post Price List338935502022-10-03 21:15:5134 mins ago0x491e59c255c790d4e3a53cec2632524088f1aaa4 IN  0x2fe5e5d341cffa606a5d9da1b6b646a381b0f7ec0 MATIC0.0047555 100.000000014
0xaa7f8ba1e5dbf8314f14213b97c9a64520f82e38d76c4a0532363c01dcf318eePost Price338935152022-10-03 21:14:4136 mins ago0x491e59c255c790d4e3a53cec2632524088f1aaa4 IN  0x2fe5e5d341cffa606a5d9da1b6b646a381b0f7ec0 MATIC0.0034184 100.000000017
0x15c9537a8980b3b710c8b663a49a24ec17cd02a750f4a4e9ccd8bd0f45e3c735Post Price List338933832022-10-03 21:10:0940 mins ago0x491e59c255c790d4e3a53cec2632524088f1aaa4 IN  0x2fe5e5d341cffa606a5d9da1b6b646a381b0f7ec0 MATIC0.0041543 100.000000013
0xa4805af2359618b8dc69d46b79a4a7b65d1d3ef5b26cafb5eb25fcc097ae2f5dPost Price338933462022-10-03 21:08:4941 mins ago0x491e59c255c790d4e3a53cec2632524088f1aaa4 IN  0x2fe5e5d341cffa606a5d9da1b6b646a381b0f7ec0 MATIC0.0034172 100.000000011
0x18a9270dd1b7debfba872e33576593a634ead4f80a1c8b4d34d627f917877c93Post Price List338933172022-10-03 21:07:5142 mins ago0x491e59c255c790d4e3a53cec2632524088f1aaa4 IN  0x2fe5e5d341cffa606a5d9da1b6b646a381b0f7ec0 MATIC0.0047555 100.000000015
0xedada5c95c1eea73a53ea95d57102f79c9ff59234b1af2d7bd364a2d408fe27bPost Price List338932772022-10-03 21:06:2444 mins ago0x491e59c255c790d4e3a53cec2632524088f1aaa4 IN  0x2fe5e5d341cffa606a5d9da1b6b646a381b0f7ec0 MATIC0.0047567 100.000000013
0xe092912c2af4c740a5e0f805e64fdf2a97c0076c43cee346113c84395f90661dPost Price List338932022022-10-03 21:03:4647 mins ago0x491e59c255c790d4e3a53cec2632524088f1aaa4 IN  0x2fe5e5d341cffa606a5d9da1b6b646a381b0f7ec0 MATIC0.0041603 100.000000012
[ Download CSV Export 
Parent Txn Hash Block From To Value
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
Wooracle

Compiler Version
v0.6.12+commit.27d51765

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion

Contract Source Code (Solidity Standard Json-Input format)

File 1 of 3 : Wooracle_avax_ftm.sol
// SPDX-License-Identifier: MIT
pragma solidity =0.6.12;
pragma experimental ABIEncoderV2;

/*

░██╗░░░░░░░██╗░█████╗░░█████╗░░░░░░░███████╗██╗
░██║░░██╗░░██║██╔══██╗██╔══██╗░░░░░░██╔════╝██║
░╚██╗████╗██╔╝██║░░██║██║░░██║█████╗█████╗░░██║
░░████╔═████║░██║░░██║██║░░██║╚════╝██╔══╝░░██║
░░╚██╔╝░╚██╔╝░╚█████╔╝╚█████╔╝░░░░░░██║░░░░░██║
░░░╚═╝░░░╚═╝░░░╚════╝░░╚════╝░░░░░░░╚═╝░░░░░╚═╝

*
* MIT License
* ===========
*
* Copyright (c) 2020 WooTrade
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/

import './libraries/InitializableOwnable.sol';
import './interfaces/IWooracle.sol';

/// @title Wooracle implementation in Fantom and Avalanche chain and other layer2 chains.
/// @notice Will be maintained and updated periodically by Woo.network in multichains.
contract Wooracle is InitializableOwnable, IWooracle {
    /* ----- State variables ----- */

    struct TokenInfo {
        uint256 price; // 18 - base_decimal + quote_decimal
        uint256 coeff; // 36 - quote
        uint256 spread; // 18
    }

    mapping(address => TokenInfo) public infos;

    address public override quoteToken;
    uint256 public override timestamp;

    uint256 public staleDuration;

    constructor() public {
        initOwner(msg.sender);
        staleDuration = uint256(300);
    }

    /* ----- External Functions ----- */

    /// @dev Set the quote token address.
    /// @param newQuoteToken token address
    function setQuoteToken(address newQuoteToken) external onlyOwner {
        quoteToken = newQuoteToken;
    }

    /// @dev Set the staleDuration.
    /// @param newStaleDuration the new stale duration
    function setStaleDuration(uint256 newStaleDuration) external onlyOwner {
        staleDuration = newStaleDuration;
    }

    /// @dev Update the base token prices.
    /// @param base the baseToken address
    /// @param newPrice the new prices for the base token
    function postPrice(address base, uint256 newPrice) external onlyOwner {
        infos[base].price = newPrice;
        timestamp = block.timestamp;
    }

    /// @dev batch update baseTokens prices
    /// @param bases list of baseToken address
    /// @param newPrices the updated prices list
    function postPriceList(address[] calldata bases, uint256[] calldata newPrices) external onlyOwner {
        uint256 length = bases.length;
        require(length == newPrices.length, 'Wooracle: length_INVALID');

        for (uint256 i = 0; i < length; i++) {
            infos[bases[i]].price = newPrices[i];
        }

        timestamp = block.timestamp;
    }

    /// @dev update the spreads info.
    /// @param base baseToken address
    /// @param newSpread the new spreads
    function postSpread(address base, uint256 newSpread) external onlyOwner {
        infos[base].spread = newSpread;
        timestamp = block.timestamp;
    }

    /// @dev batch update the spreads info.
    /// @param bases list of baseToken address
    /// @param newSpreads list of spreads info
    function postSpreadList(address[] calldata bases, uint256[] calldata newSpreads) external onlyOwner {
        uint256 length = bases.length;
        require(length == newSpreads.length, 'Wooracle: length_INVALID');

        for (uint256 i = 0; i < length; i++) {
            infos[bases[i]].spread = newSpreads[i];
        }

        timestamp = block.timestamp;
    }

    /// @dev update the state of the given base token.
    /// @param base baseToken address
    /// @param newPrice the new prices
    /// @param newSpread the new spreads
    /// @param newCoeff the new slippage coefficent
    function postState(
        address base,
        uint256 newPrice,
        uint256 newSpread,
        uint256 newCoeff
    ) external onlyOwner {
        _setState(base, newPrice, newSpread, newCoeff);
        timestamp = block.timestamp;
    }

    /// @dev batch update the prices, spreads and slipagge coeffs info.
    /// @param bases list of baseToken address
    /// @param newPrices the prices list
    /// @param newSpreads the spreads list
    /// @param newCoeffs the slippage coefficent list
    function postStateList(
        address[] calldata bases,
        uint256[] calldata newPrices,
        uint256[] calldata newSpreads,
        uint256[] calldata newCoeffs
    ) external onlyOwner {
        uint256 length = bases.length;
        require(
            length == newPrices.length && length == newSpreads.length && length == newCoeffs.length,
            'Wooracle: length_INVALID'
        );

        for (uint256 i = 0; i < length; i++) {
            _setState(bases[i], newPrices[i], newSpreads[i], newCoeffs[i]);
        }
        timestamp = block.timestamp;
    }

    /// @inheritdoc IWooracle
    function price(address base) external view override returns (uint256 priceNow, bool feasible) {
        priceNow = infos[base].price;
        feasible = priceNow != 0 && block.timestamp <= (timestamp + staleDuration * 1 seconds);
    }

    function getPrice(address base) external view override returns (uint256) {
        return infos[base].price;
    }

    function getSpread(address base) external view override returns (uint256) {
        return infos[base].spread;
    }

    function getCoeff(address base) external view override returns (uint256) {
        return infos[base].coeff;
    }

    /// @inheritdoc IWooracle
    function state(address base)
        external
        view
        override
        returns (
            uint256 priceNow,
            uint256 spreadNow,
            uint256 coeffNow,
            bool feasible
        )
    {
        TokenInfo storage info = infos[base];
        priceNow = info.price;
        spreadNow = info.spread;
        coeffNow = info.coeff;
        feasible = priceNow != 0 && block.timestamp <= (timestamp + staleDuration * 1 seconds);
    }

    function isFeasible(address base) public view override returns (bool) {
        return infos[base].price != 0 && block.timestamp <= (timestamp + staleDuration * 1 seconds);
    }

    /* ----- Private Functions ----- */

    function _setState(
        address base,
        uint256 newPrice,
        uint256 newSpread,
        uint256 newCoeff
    ) private {
        TokenInfo storage info = infos[base];
        info.price = newPrice;
        info.spread = newSpread;
        info.coeff = newCoeff;
    }
}

File 2 of 3 : InitializableOwnable.sol
// SPDX-License-Identifier: MIT
pragma solidity =0.6.12;
pragma experimental ABIEncoderV2;

/**
 * @title Ownable initializable contract.
 *
 * @notice Ownership related functions
 */
contract InitializableOwnable {
    address public _OWNER_;
    address public _NEW_OWNER_;
    bool internal _INITIALIZED_;

    // ============ Events ============

    event OwnershipTransferPrepared(address indexed previousOwner, address indexed newOwner);

    event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);

    // ============ Modifiers ============

    modifier notInitialized() {
        require(!_INITIALIZED_, 'InitializableOwnable: SHOULD_NOT_BE_INITIALIZED');
        _;
    }

    modifier onlyOwner() {
        require(msg.sender == _OWNER_, 'InitializableOwnable: NOT_OWNER');
        _;
    }

    // ============ Functions ============

    /// @dev Init _OWNER_ from newOwner and set _INITIALIZED_ as true
    /// @param newOwner new owner address
    function initOwner(address newOwner) public notInitialized {
        _INITIALIZED_ = true;
        _OWNER_ = newOwner;
    }

    /// @dev Set _NEW_OWNER_ from newOwner
    /// @param newOwner new owner address
    function transferOwnership(address newOwner) public onlyOwner {
        emit OwnershipTransferPrepared(_OWNER_, newOwner);
        _NEW_OWNER_ = newOwner;
    }

    /// @dev Set _OWNER_ from _NEW_OWNER_ and set _NEW_OWNER_ equal zero address
    function claimOwnership() public {
        require(msg.sender == _NEW_OWNER_, 'InitializableOwnable: INVALID_CLAIM');
        emit OwnershipTransferred(_OWNER_, _NEW_OWNER_);
        _OWNER_ = _NEW_OWNER_;
        _NEW_OWNER_ = address(0);
    }
}

File 3 of 3 : IWooracle.sol
// SPDX-License-Identifier: MIT
pragma solidity =0.6.12;
pragma experimental ABIEncoderV2;

/*

░██╗░░░░░░░██╗░█████╗░░█████╗░░░░░░░███████╗██╗
░██║░░██╗░░██║██╔══██╗██╔══██╗░░░░░░██╔════╝██║
░╚██╗████╗██╔╝██║░░██║██║░░██║█████╗█████╗░░██║
░░████╔═████║░██║░░██║██║░░██║╚════╝██╔══╝░░██║
░░╚██╔╝░╚██╔╝░╚█████╔╝╚█████╔╝░░░░░░██║░░░░░██║
░░░╚═╝░░░╚═╝░░░╚════╝░░╚════╝░░░░░░░╚═╝░░░░░╚═╝

*
* MIT License
* ===========
*
* Copyright (c) 2020 WooTrade
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/

/// @title The oracle interface by Woo.Network.
/// @notice update and posted the latest price info by Woo.
interface IWooracle {
    /// @dev the quote token for Wooracle's pricing.
    /// @return the quote token
    function quoteToken() external view returns (address);

    /// @dev the price for the given base token
    /// @param base baseToken address
    /// @return priceNow the current price of base token
    /// @return feasible whether the current price is feasible and valid
    function price(address base) external view returns (uint256 priceNow, bool feasible);

    function getPrice(address base) external view returns (uint256);

    function getSpread(address base) external view returns (uint256);

    function getCoeff(address base) external view returns (uint256);

    /// @dev returns the state for the given base token.
    /// @param base baseToken address
    /// @return priceNow the current price of base token
    /// @return spreadNow the current spread of base token
    /// @return coeffNow the slippage coefficient of base token
    /// @return feasible whether the current state is feasible and valid
    function state(address base)
        external
        view
        returns (
            uint256 priceNow,
            uint256 spreadNow,
            uint256 coeffNow,
            bool feasible
        );

    /// @dev returns the last updated timestamp
    /// @return the last updated timestamp
    function timestamp() external view returns (uint256);

    /// @dev returns whether the base token price is valid.
    /// @param base baseToken address
    /// @return whether the base token price is valid.
    function isFeasible(address base) external view returns (bool);
}

Settings
{
  "evmVersion": "istanbul",
  "optimizer": {
    "enabled": true,
    "runs": 200
  },
  "outputSelection": {
    "*": {
      "*": [
        "evm.bytecode",
        "evm.deployedBytecode",
        "devdoc",
        "userdoc",
        "metadata",
        "abi"
      ]
    }
  },
  "libraries": {}
}

Contract Security Audit

Contract ABI

[{"inputs":[],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferPrepared","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"inputs":[],"name":"_NEW_OWNER_","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"_OWNER_","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"claimOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"base","type":"address"}],"name":"getCoeff","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"base","type":"address"}],"name":"getPrice","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"base","type":"address"}],"name":"getSpread","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"infos","outputs":[{"internalType":"uint256","name":"price","type":"uint256"},{"internalType":"uint256","name":"coeff","type":"uint256"},{"internalType":"uint256","name":"spread","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"initOwner","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"base","type":"address"}],"name":"isFeasible","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"base","type":"address"},{"internalType":"uint256","name":"newPrice","type":"uint256"}],"name":"postPrice","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"bases","type":"address[]"},{"internalType":"uint256[]","name":"newPrices","type":"uint256[]"}],"name":"postPriceList","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"base","type":"address"},{"internalType":"uint256","name":"newSpread","type":"uint256"}],"name":"postSpread","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"bases","type":"address[]"},{"internalType":"uint256[]","name":"newSpreads","type":"uint256[]"}],"name":"postSpreadList","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"base","type":"address"},{"internalType":"uint256","name":"newPrice","type":"uint256"},{"internalType":"uint256","name":"newSpread","type":"uint256"},{"internalType":"uint256","name":"newCoeff","type":"uint256"}],"name":"postState","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"bases","type":"address[]"},{"internalType":"uint256[]","name":"newPrices","type":"uint256[]"},{"internalType":"uint256[]","name":"newSpreads","type":"uint256[]"},{"internalType":"uint256[]","name":"newCoeffs","type":"uint256[]"}],"name":"postStateList","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"base","type":"address"}],"name":"price","outputs":[{"internalType":"uint256","name":"priceNow","type":"uint256"},{"internalType":"bool","name":"feasible","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"quoteToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newQuoteToken","type":"address"}],"name":"setQuoteToken","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"newStaleDuration","type":"uint256"}],"name":"setStaleDuration","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"staleDuration","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"base","type":"address"}],"name":"state","outputs":[{"internalType":"uint256","name":"priceNow","type":"uint256"},{"internalType":"uint256","name":"spreadNow","type":"uint256"},{"internalType":"uint256","name":"coeffNow","type":"uint256"},{"internalType":"bool","name":"feasible","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"timestamp","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"}]

608060405234801561001057600080fd5b5061001a33610025565b61012c6005556100dd565b600154600160a01b900460ff16156100585760405162461bcd60e51b815260040161004f9061008e565b60405180910390fd5b6001805460ff60a01b1916600160a01b179055600080546001600160a01b039092166001600160a01b0319909216919091179055565b6020808252602f908201527f496e697469616c697a61626c654f776e61626c653a2053484f554c445f4e4f5460408201526e17d09157d253925512505312569151608a1b606082015260800190565b610da2806100ec6000396000f3fe608060405234801561001057600080fd5b506004361061014d5760003560e01c80636eb54beb116100c3578063aa5fd4491161007c578063aa5fd449146102ab578063aea91078146102be578063b80777ea146102df578063c6ddb642146102e7578063cc6864b114610309578063f2fde38b146103115761014d565b80636eb54beb146102445780638456db1514610257578063909dd4d71461025f57806393e45a391461027257806399235fd4146102855780639b4bd754146102985761014d565b806341976e091161011557806341976e09146101c3578063439bba33146101e35780634e71e0c81461020357806350a4a5c91461020b5780635684c91e1461021e5780636b7cb1ac146102315761014d565b80630d0092971461015257806316048bc4146101675780631cfb886d14610185578063217a4b701461019857806331e658a5146101a0575b600080fd5b610165610160366004610a30565b610324565b005b61016f61038d565b60405161017c9190610c01565b60405180910390f35b610165610193366004610a30565b61039c565b61016f6103e8565b6101b36101ae366004610a30565b6103f7565b60405161017c9493929190610d4f565b6101d66101d1366004610a30565b610440565b60405161017c9190610d20565b6101f66101f1366004610a30565b61045b565b60405161017c9190610c15565b61016561048e565b610165610219366004610a52565b61051c565b61016561022c366004610ac1565b61056a565b61016561023f366004610ac1565b610625565b610165610252366004610a7c565b6106d7565b61016f610717565b61016561026d366004610b2a565b610726565b6101d6610280366004610a30565b61080b565b610165610293366004610be9565b610829565b6101d66102a6366004610a30565b610858565b6101656102b9366004610a52565b610877565b6102d16102cc366004610a30565b6108c1565b60405161017c929190610d29565b6101d66108f7565b6102fa6102f5366004610a30565b6108fd565b60405161017c93929190610d39565b6101d661091d565b61016561031f366004610a30565b610923565b600154600160a01b900460ff16156103575760405162461bcd60e51b815260040161034e90610c8e565b60405180910390fd5b6001805460ff60a01b1916600160a01b179055600080546001600160a01b039092166001600160a01b0319909216919091179055565b6000546001600160a01b031681565b6000546001600160a01b031633146103c65760405162461bcd60e51b815260040161034e90610c57565b600380546001600160a01b0319166001600160a01b0392909216919091179055565b6003546001600160a01b031681565b6001600160a01b038116600090815260026020819052604082208054918101546001820154929390929184158015906104365750600554600454014211155b9150509193509193565b6001600160a01b031660009081526002602052604090205490565b6001600160a01b038116600090815260026020526040812054158015906104885750600554600454014211155b92915050565b6001546001600160a01b031633146104b85760405162461bcd60e51b815260040161034e90610cdd565b600154600080546040516001600160a01b0393841693909116917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a360018054600080546001600160a01b03199081166001600160a01b03841617909155169055565b6000546001600160a01b031633146105465760405162461bcd60e51b815260040161034e90610c57565b6001600160a01b039091166000908152600260208190526040909120015542600455565b6000546001600160a01b031633146105945760405162461bcd60e51b815260040161034e90610c57565b828181146105b45760405162461bcd60e51b815260040161034e90610c20565b60005b81811015610619578383828181106105cb57fe5b90506020020135600260008888858181106105e257fe5b90506020020160208101906105f79190610a30565b6001600160a01b031681526020810191909152604001600020556001016105b7565b50504260045550505050565b6000546001600160a01b0316331461064f5760405162461bcd60e51b815260040161034e90610c57565b8281811461066f5760405162461bcd60e51b815260040161034e90610c20565b60005b818110156106195783838281811061068657fe5b905060200201356002600088888581811061069d57fe5b90506020020160208101906106b29190610a30565b6001600160a01b03168152602081019190915260400160002060020155600101610672565b6000546001600160a01b031633146107015760405162461bcd60e51b815260040161034e90610c57565b61070d848484846109a8565b5050426004555050565b6001546001600160a01b031681565b6000546001600160a01b031633146107505760405162461bcd60e51b815260040161034e90610c57565b86858114801561075f57508084145b801561076a57508082145b6107865760405162461bcd60e51b815260040161034e90610c20565b60005b818110156107fb576107f38a8a838181106107a057fe5b90506020020160208101906107b59190610a30565b8989848181106107c157fe5b905060200201358888858181106107d457fe5b905060200201358787868181106107e757fe5b905060200201356109a8565b600101610789565b5050426004555050505050505050565b6001600160a01b031660009081526002602052604090206001015490565b6000546001600160a01b031633146108535760405162461bcd60e51b815260040161034e90610c57565b600555565b6001600160a01b03166000908152600260208190526040909120015490565b6000546001600160a01b031633146108a15760405162461bcd60e51b815260040161034e90610c57565b6001600160a01b0390911660009081526002602052604090205542600455565b6001600160a01b0381166000908152600260205260408120549081158015906108f05750600554600454014211155b9050915091565b60045481565b600260208190526000918252604090912080546001820154919092015483565b60055481565b6000546001600160a01b0316331461094d5760405162461bcd60e51b815260040161034e90610c57565b600080546040516001600160a01b03808516939216917fdcf55418cee3220104fef63f979ff3c4097ad240c0c43dcb33ce837748983e6291a3600180546001600160a01b0319166001600160a01b0392909216919091179055565b6001600160a01b03909316600090815260026020819052604090912092835582015560010155565b80356001600160a01b038116811461048857600080fd5b60008083601f8401126109f8578182fd5b50813567ffffffffffffffff811115610a0f578182fd5b6020830191508360208083028501011115610a2957600080fd5b9250929050565b600060208284031215610a41578081fd5b610a4b83836109d0565b9392505050565b60008060408385031215610a64578081fd5b610a6e84846109d0565b946020939093013593505050565b60008060008060808587031215610a91578182fd5b84356001600160a01b0381168114610aa7578283fd5b966020860135965060408601359560600135945092505050565b60008060008060408587031215610ad6578384fd5b843567ffffffffffffffff80821115610aed578586fd5b610af9888389016109e7565b90965094506020870135915080821115610b11578384fd5b50610b1e878288016109e7565b95989497509550505050565b6000806000806000806000806080898b031215610b45578384fd5b883567ffffffffffffffff80821115610b5c578586fd5b610b688c838d016109e7565b909a50985060208b0135915080821115610b80578586fd5b610b8c8c838d016109e7565b909850965060408b0135915080821115610ba4578586fd5b610bb08c838d016109e7565b909650945060608b0135915080821115610bc8578384fd5b50610bd58b828c016109e7565b999c989b5096995094979396929594505050565b600060208284031215610bfa578081fd5b5035919050565b6001600160a01b0391909116815260200190565b901515815260200190565b60208082526018908201527f576f6f7261636c653a206c656e6774685f494e56414c49440000000000000000604082015260600190565b6020808252601f908201527f496e697469616c697a61626c654f776e61626c653a204e4f545f4f574e455200604082015260600190565b6020808252602f908201527f496e697469616c697a61626c654f776e61626c653a2053484f554c445f4e4f5460408201526e17d09157d253925512505312569151608a1b606082015260800190565b60208082526023908201527f496e697469616c697a61626c654f776e61626c653a20494e56414c49445f434c60408201526241494d60e81b606082015260800190565b90815260200190565b9182521515602082015260400190565b9283526020830191909152604082015260600190565b93845260208401929092526040830152151560608201526080019056fea26469706673582212200cc3cac1460f9da2d3f0e572dda7c820b72ecc0f99511fca924321f98e38f94964736f6c634300060c0033

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.