Contract 0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a

Contract Overview

Balance:
0 Ether
TxHash Block Age From To Value [TxFee]
0x2c32f7d739e5ab72d9033a4d15fd5cbdc06c8cc69de69754039aa02f062fead452510987 hrs 7 mins ago0x0d06535c3ef54c6cca7775924f64278f0e4daf07 IN  0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0 Ether0.000083043
0xfe50f9a3830a19101443663ce5f42c7bda72c578f29d2aedb8849cc9a8794fbc524821017 hrs 56 mins ago0x0d06535c3ef54c6cca7775924f64278f0e4daf07 IN  0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0 Ether0.000171039
0xf40e9a395cda4e52be6a9c7d431bc7b165ab48c21e8026c42ad62e275838681f524815018 hrs 6 mins ago0x0d06535c3ef54c6cca7775924f64278f0e4daf07 IN  0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0 Ether0.000083043
0x11add88598215ab8fc8b529a16472067df433e0baebfcdc00258daaa2136d459524790719 hrs 7 mins ago0x0d06535c3ef54c6cca7775924f64278f0e4daf07 IN  0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0 Ether0.000083043
0x8cd81266bc15705af842cca0b4ea57556c40521e9ae88a683355d68291efcdd9524705922 hrs 24 mins ago0x0d06535c3ef54c6cca7775924f64278f0e4daf07 IN  0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0 Ether0.000083043
0x4a567a83b613b50edbbcb30c726298432794a437d4292abe673af9ab2237702a524704422 hrs 27 mins ago0x0d06535c3ef54c6cca7775924f64278f0e4daf07 IN  0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0 Ether0.000083043
0xc8daf5522077d2c82a55232b912225b48e857d3ff887aa11b0644441951c7d89524703222 hrs 28 mins ago0x0d06535c3ef54c6cca7775924f64278f0e4daf07 IN  0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0 Ether0.000083043
0xf72f2a54e2fca7d1ccbf48d8d394fac5a42d041a5db67414ac4d8b44420c1ad7524702922 hrs 29 mins ago0x0d06535c3ef54c6cca7775924f64278f0e4daf07 IN  0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0 Ether0.000083043
0x3da5b2181b689ea728a69a0b2336b3e6afdcd3921342ea13d97dc468f338f042524701122 hrs 35 mins ago0x0d06535c3ef54c6cca7775924f64278f0e4daf07 IN  0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0 Ether0.000083043
0xf3da07d148c1c5409f38b62cb75cda32e7a12415480f29ce35f0681597a34597524700322 hrs 36 mins ago0x0d06535c3ef54c6cca7775924f64278f0e4daf07 IN  0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0 Ether0.000083043
0x2669611fb762afd6c6ee59a15595d5bf2be47b0f09236937db5269035dbd0d5d524699722 hrs 39 mins ago0x0d06535c3ef54c6cca7775924f64278f0e4daf07 IN  0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0 Ether0.000083043
0xe8d9aeef5f7ede314445ccf561c389e0143aa14ce4ccf75fd7db4eb6f41f8c6d524698922 hrs 40 mins ago0x0d06535c3ef54c6cca7775924f64278f0e4daf07 IN  0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0 Ether0.000083043
0xe0b0c32d18496046db6bed826f1c57c8c9aba743c4782f1a2e8324c888025026524698622 hrs 41 mins ago0x0d06535c3ef54c6cca7775924f64278f0e4daf07 IN  0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0 Ether0.000083043
0x26e58e234b9050e0a607bfae51203b95c85b2a0189813286b49323b68f5f8082524698222 hrs 42 mins ago0x0d06535c3ef54c6cca7775924f64278f0e4daf07 IN  0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0 Ether0.000082979
0xdac19543e928fb12916b79a66e5cb92834fa2bfc172bdfdbf7c3c791e60133ff524695522 hrs 48 mins ago0x0d06535c3ef54c6cca7775924f64278f0e4daf07 IN  0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0 Ether0.000083043
0x205d7f2098f4fdc7489473f02f4f635dbbb0fc1993f012fb29c9549c17492877524694022 hrs 52 mins ago0x0d06535c3ef54c6cca7775924f64278f0e4daf07 IN  0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0 Ether0.000083043
0x4df7bff297cfbb0b8674615c100dbae157878caa34e5f6fd6660c7c22108e138524692322 hrs 55 mins ago0x0d06535c3ef54c6cca7775924f64278f0e4daf07 IN  0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0 Ether0.000083043
0x7c8e12e72eed875c381ea9b81076ba7ca289e4fb00882b04205e049de81bf364524691122 hrs 58 mins ago0x0d06535c3ef54c6cca7775924f64278f0e4daf07 IN  0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0 Ether0.000083043
0x94e8b28756c18953a5f8999072650cc67441bc347c1a510b96c94e6b36515d3e524690223 hrs ago0x0d06535c3ef54c6cca7775924f64278f0e4daf07 IN  0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0 Ether0.000082979
0x049d78ed9968dea890250e5d9ca4a95575939a5c1a67dea0731f74aa66ccdd8a524689123 hrs 2 mins ago0x0d06535c3ef54c6cca7775924f64278f0e4daf07 IN  0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0 Ether0.000083043
0x0d0da71b2d0bd8b15b2879ce6faa5c1505f4b753ede881e52b7e4933b586e246524687623 hrs 7 mins ago0x0d06535c3ef54c6cca7775924f64278f0e4daf07 IN  0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0 Ether0.000083043
0x0e02f0e1a7b7f765b5710ac3c2e86172b1e34a75469dcd2e9627fbf14124b8fb524686123 hrs 10 mins ago0x0d06535c3ef54c6cca7775924f64278f0e4daf07 IN  0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0 Ether0.000083043
0x517f3b9a4f7d30375d868bc6d72de7828f659ba23c069e0dc1e80cfa4ae61fa1524685623 hrs 12 mins ago0x0d06535c3ef54c6cca7775924f64278f0e4daf07 IN  0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0 Ether0.000083043
0xf93b6c90e51d1b9b391b96eb5a8e03964fa1e05bf0f38980b9a2800bade8ec09524684523 hrs 14 mins ago0x0d06535c3ef54c6cca7775924f64278f0e4daf07 IN  0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0 Ether0.000083043
0x0915313a6699b09a66015a5fed1a8c97f6f2a91e1da85d3bc63236a51da755bc52450281 day 6 hrs ago0x0d06535c3ef54c6cca7775924f64278f0e4daf07 IN  0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0 Ether0.000083043
[ Download CSV Export 

Latest 25 internal transaction, Click here to view more Internal Transactions as a result of Contract Execution

Parent TxHash Block Age From To Value
0x171dfde75a736972bac58ba730f7eda563a7cd691a053a9d7a22b45b4bf63aad52510957 hrs 8 mins ago0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0xbbbe9aebf16a729228f06b2f83d82366bcfc80c00 Ether
0x171dfde75a736972bac58ba730f7eda563a7cd691a053a9d7a22b45b4bf63aad52510957 hrs 8 mins ago0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0xac3e41fb70cc1914b3b9707c6151d7eb6df855cc0 Ether
0x171dfde75a736972bac58ba730f7eda563a7cd691a053a9d7a22b45b4bf63aad52510957 hrs 8 mins ago0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0xbbbe9aebf16a729228f06b2f83d82366bcfc80c00 Ether
0x171dfde75a736972bac58ba730f7eda563a7cd691a053a9d7a22b45b4bf63aad52510957 hrs 8 mins ago0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0xac3e41fb70cc1914b3b9707c6151d7eb6df855cc0 Ether
0x171dfde75a736972bac58ba730f7eda563a7cd691a053a9d7a22b45b4bf63aad52510957 hrs 8 mins ago0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0xf11c0ebd11ef967918bd2ff5ecf76731c65b49180 Ether
0x171dfde75a736972bac58ba730f7eda563a7cd691a053a9d7a22b45b4bf63aad52510957 hrs 8 mins ago0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0xac3e41fb70cc1914b3b9707c6151d7eb6df855cc0 Ether
0x171dfde75a736972bac58ba730f7eda563a7cd691a053a9d7a22b45b4bf63aad52510957 hrs 8 mins ago0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0xf11c0ebd11ef967918bd2ff5ecf76731c65b49180 Ether
0x171dfde75a736972bac58ba730f7eda563a7cd691a053a9d7a22b45b4bf63aad52510957 hrs 8 mins ago0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0xac3e41fb70cc1914b3b9707c6151d7eb6df855cc0 Ether
0x171dfde75a736972bac58ba730f7eda563a7cd691a053a9d7a22b45b4bf63aad52510957 hrs 8 mins ago0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0xac3e41fb70cc1914b3b9707c6151d7eb6df855cc0 Ether
0x171dfde75a736972bac58ba730f7eda563a7cd691a053a9d7a22b45b4bf63aad52510957 hrs 8 mins ago0x47e723cf30cd55c89f1f896f2d5823ecc57890ad0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0 Ether
0x171dfde75a736972bac58ba730f7eda563a7cd691a053a9d7a22b45b4bf63aad52510957 hrs 8 mins ago0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0x47e723cf30cd55c89f1f896f2d5823ecc57890ad0 Ether
0x171dfde75a736972bac58ba730f7eda563a7cd691a053a9d7a22b45b4bf63aad52510957 hrs 8 mins ago0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0xf11c0ebd11ef967918bd2ff5ecf76731c65b49180 Ether
0x171dfde75a736972bac58ba730f7eda563a7cd691a053a9d7a22b45b4bf63aad52510957 hrs 8 mins ago0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0xac3e41fb70cc1914b3b9707c6151d7eb6df855cc0 Ether
0x171dfde75a736972bac58ba730f7eda563a7cd691a053a9d7a22b45b4bf63aad52510957 hrs 8 mins ago0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0x47e723cf30cd55c89f1f896f2d5823ecc57890ad0 Ether
0x171dfde75a736972bac58ba730f7eda563a7cd691a053a9d7a22b45b4bf63aad52510957 hrs 8 mins ago0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0xac3e41fb70cc1914b3b9707c6151d7eb6df855cc0 Ether
0x171dfde75a736972bac58ba730f7eda563a7cd691a053a9d7a22b45b4bf63aad52510957 hrs 8 mins ago0xbbbe9aebf16a729228f06b2f83d82366bcfc80c00xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0 Ether
0x683111ac21482234a95d1ad924d540c06cbaa9e82a5492982d471df4ba26cb5c524820417 hrs 58 mins ago0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0xbbbe9aebf16a729228f06b2f83d82366bcfc80c00 Ether
0x683111ac21482234a95d1ad924d540c06cbaa9e82a5492982d471df4ba26cb5c524820417 hrs 58 mins ago0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0xac3e41fb70cc1914b3b9707c6151d7eb6df855cc0 Ether
0x683111ac21482234a95d1ad924d540c06cbaa9e82a5492982d471df4ba26cb5c524820417 hrs 58 mins ago0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0xbbbe9aebf16a729228f06b2f83d82366bcfc80c00 Ether
0x683111ac21482234a95d1ad924d540c06cbaa9e82a5492982d471df4ba26cb5c524820417 hrs 58 mins ago0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0xac3e41fb70cc1914b3b9707c6151d7eb6df855cc0 Ether
0x683111ac21482234a95d1ad924d540c06cbaa9e82a5492982d471df4ba26cb5c524820417 hrs 58 mins ago0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0xf11c0ebd11ef967918bd2ff5ecf76731c65b49180 Ether
0x683111ac21482234a95d1ad924d540c06cbaa9e82a5492982d471df4ba26cb5c524820417 hrs 58 mins ago0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0xac3e41fb70cc1914b3b9707c6151d7eb6df855cc0 Ether
0x683111ac21482234a95d1ad924d540c06cbaa9e82a5492982d471df4ba26cb5c524820417 hrs 58 mins ago0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0xf11c0ebd11ef967918bd2ff5ecf76731c65b49180 Ether
0x683111ac21482234a95d1ad924d540c06cbaa9e82a5492982d471df4ba26cb5c524820417 hrs 58 mins ago0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0xac3e41fb70cc1914b3b9707c6151d7eb6df855cc0 Ether
0x683111ac21482234a95d1ad924d540c06cbaa9e82a5492982d471df4ba26cb5c524820417 hrs 58 mins ago0xdad3f15f5ca0635b95c74538f9918b4ee46ddb3a0xac3e41fb70cc1914b3b9707c6151d7eb6df855cc0 Ether
[ Download CSV Export 
Warning: The compiled contract might be susceptible to ExpExponentCleanup (medium/high-severity), EventStructWrongData (very low-severity) Solidity Compiler Bugs.

Contract Source Code Verified (Similar Match)
Note: This contract matches the deployed ByteCode of the Verified Source Code for Contract 0xc180d882cbfe2d38b38915bea0a53fe55473daec

Contract Name:
VpfsContract

Compiler Version
v0.4.24+commit.e67f0147

Optimization Enabled:
Yes

Runs (Optimizer):
200

Contract Source Code

pragma solidity ^0.4.23;

// File: contracts/VpfFactoryInterface.sol

contract VpfFactoryInterface {
    function generateNext() public;
    function isPaused() public view returns(bool);
}

// File: openzeppelin-solidity/contracts/ownership/Ownable.sol

/**
 * @title Ownable
 * @dev The Ownable contract has an owner address, and provides basic authorization control
 * functions, this simplifies the implementation of "user permissions".
 */
contract Ownable {
  address public owner;


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


  /**
   * @dev The Ownable constructor sets the original `owner` of the contract to the sender
   * account.
   */
  constructor() public {
    owner = msg.sender;
  }

  /**
   * @dev Throws if called by any account other than the owner.
   */
  modifier onlyOwner() {
    require(msg.sender == owner);
    _;
  }

  /**
   * @dev Allows the current owner to relinquish control of the contract.
   */
  function renounceOwnership() public onlyOwner {
    emit OwnershipRenounced(owner);
    owner = address(0);
  }

  /**
   * @dev Allows the current owner to transfer control of the contract to a newOwner.
   * @param _newOwner The address to transfer ownership to.
   */
  function transferOwnership(address _newOwner) public onlyOwner {
    _transferOwnership(_newOwner);
  }

  /**
   * @dev Transfers control of the contract to a newOwner.
   * @param _newOwner The address to transfer ownership to.
   */
  function _transferOwnership(address _newOwner) internal {
    require(_newOwner != address(0));
    emit OwnershipTransferred(owner, _newOwner);
    owner = _newOwner;
  }
}

// File: contracts/oracles/OracleInterface.sol

contract OracleInterface {
    function request(
        bytes32 _assetHash,
        uint _time,
        uint8 _decimalPoints,
        uint _gasLimit) public;
}

// File: contracts/PhenomenonsContract.sol

contract PhenomenonsContract is Ownable {

    struct Phenomenon {
        string mnemonic;
        string name;
        string description;
        string category;
        uint8 valueDecimalPlaces;
        bool enabled;
        bool exists;
    }

    mapping(bytes32 => Phenomenon) public phenomenons;
    string[] public mnemonics;

    event PhenomenonAdd(bytes32 hash);
    event PhenomenonDisable(bytes32 hash);
    event PhenomenonEnable(bytes32 hash);

    function addPhenomenon(
        string _mnemonic,
        string _name,
        string _description,
        string _category,
        uint8 _valueDecimalPlaces
    ) public onlyOwner
    {
        bytes32 hash = keccak256(abi.encodePacked(_mnemonic));
        require(bytes(phenomenons[hash].mnemonic).length == 0, "Phenomenon already exists!");

        Phenomenon memory phenomenon = Phenomenon(
            _mnemonic,
            _name,
            _description,
            _category,
            _valueDecimalPlaces,
            true,
            true
        );

        phenomenons[hash] = phenomenon;
        mnemonics.push(_mnemonic);

        emit PhenomenonAdd(hash);
    }

    function disablePhenomenon(bytes32 _hash) public onlyOwner {
        require(phenomenons[_hash].enabled == true);

        phenomenons[_hash].enabled = false;

        emit PhenomenonDisable(_hash);
    }

    function enablePhenomenon(bytes32 _hash) public onlyOwner {
        require(phenomenons[_hash].exists == true);
        require(phenomenons[_hash].enabled == false);

        phenomenons[_hash].enabled = true;

        emit PhenomenonEnable(_hash);
    }

    function mnemonicsCount() public view returns(uint) {
        return mnemonics.length;
    }

    function isEnabled(bytes32 _hash) public view returns(bool) {
        return phenomenons[_hash].enabled;
    }

    function decimalPoints(bytes32 _hash) public view returns(uint8) {
        return phenomenons[_hash].valueDecimalPlaces;
    }
}

// File: contracts/ContractAddressesManager.sol

contract ContractAddressesManager is Ownable {

    OracleInterface public oracle;
    PhenomenonsContract public phenomenonsContract;
    mapping(address => bool) public factories;

    event AddFactory(address _factory);
    event RemoveFactory(address _factory);

    function addFactory(VpfFactoryInterface _factory) public onlyOwnerOrigin {
        factories[_factory] = true;
        emit AddFactory(_factory);
    }

    function removeFactory(VpfFactoryInterface _factory) public onlyOwner {
        factories[_factory] = false;
        emit RemoveFactory(_factory);
    }

    function setOracle(OracleInterface _oracle) public onlyOwner {
        oracle = _oracle;
    }

    function setPhenomenonsContract(PhenomenonsContract _phenomenonsContract) public onlyOwner {
        phenomenonsContract = _phenomenonsContract;
    }

    modifier onlyOwnerOrigin() {
        require(tx.origin == owner);
        _;
    }
}

// File: contracts/oracles/UsingOracle.sol

contract UsingOracle {
    ContractAddressesManager addressManager;

    constructor(ContractAddressesManager _manager) public {
        addressManager = _manager;
    }

    function updateValue(bytes32 _vpfHash, uint _time, uint _value) public onlyFromOracle;

    modifier onlyFromOracle() {
        require(msg.sender == address(addressManager.oracle()));
        _;
    }
}

// File: contracts/VpfsContract.sol

contract VpfsContract is UsingOracle, Ownable {

    uint public openValueGasLimit = 200000;
    uint public resolveValueGasLimit = 1000000;
    address public serverAddress;

    struct Vpf {
        bytes32 phenomenonHash;
        uint openDate;
        uint closeDate;
        uint resolveDate;
        uint maxBeta;
        uint feePercent;
        int[] intervals;
        VpfFactoryInterface vpfFactoryInterface;
        uint tradesTotal;
        uint[] virtualTradesSummed;
        uint openValue;
        uint resolveValue;
    }

    mapping(bytes32 => Vpf) public vpfs;

    event VpfAdd(bytes32 hash);
    event VpfTradesFill(bytes32 hash);
    event VpfOpenValueCheck(bytes32 hash, uint value);
    event VpfResolveValueCheck(bytes32 hash, uint value);

    constructor(ContractAddressesManager _manager, address _serverAddress) public UsingOracle(_manager) {
        serverAddress = _serverAddress;
    }

    function addVpf(
        bytes32 _phenomenonHash,
        uint _openDate,
        uint _closeDate,
        uint _resolveDate,
        uint _maxBeta,
        uint _feePercent,
        int[] _intervals
    ) public onlyValidFactory
    {
        require(addressManager.phenomenonsContract().isEnabled(_phenomenonHash));

        bytes32 hash = vpfHash(_phenomenonHash, _openDate, _resolveDate);
        vpfs[hash] = Vpf(
            _phenomenonHash,
            _openDate,
            _closeDate,
            _resolveDate,
            _maxBeta,
            _feePercent,
            _intervals,
            VpfFactoryInterface(msg.sender),
            0,
            new uint[](0),
            0,
            0
        );
        emit VpfAdd(hash);

        uint8 decimalPoints = addressManager.phenomenonsContract().decimalPoints(_phenomenonHash);

        addressManager.oracle().request(
            hash,
            _openDate,
            decimalPoints,
            openValueGasLimit
        );
        addressManager.oracle().request(
            hash,
            _resolveDate,
            decimalPoints,
            resolveValueGasLimit
        );
    }

    function fillTradesInfo(bytes32 _vpfHash, uint _tradesTotal, uint[] _virtualTradesSummed) public onlyServer {
        Vpf storage vpf = vpfs[_vpfHash];
        require(vpf.openDate > 0);
        require(vpf.tradesTotal == 0);

        vpf.tradesTotal = _tradesTotal;
        vpf.virtualTradesSummed = _virtualTradesSummed;

        emit VpfTradesFill(_vpfHash);
    }

    function updateValue(bytes32 _vpfHash, uint _time, uint _value) public onlyFromOracle {
        Vpf storage vpf = vpfs[_vpfHash];

        require(_time == vpf.openDate || _time == vpf.resolveDate, "Time of request does not match openDate nor checkDate");

        if (_time == vpf.openDate) {
            vpf.openValue = _value;
            emit VpfOpenValueCheck(_vpfHash, _value);
        } else {
            vpf.resolveValue = _value;
            emit VpfResolveValueCheck(_vpfHash, _value);

            if (vpf.vpfFactoryInterface.isPaused() == false &&
            addressManager.phenomenonsContract().isEnabled(vpf.phenomenonHash)
            ) {
                vpf.vpfFactoryInterface.generateNext();
            }
        }
    }

    function setOpenValueGasLimit(uint _openValueGasLimit) public onlyOwner {
        openValueGasLimit = _openValueGasLimit;
    }

    function setResolveValueGasLimit(uint _resolveValueGasLimit) public onlyOwner {
        resolveValueGasLimit = _resolveValueGasLimit;
    }

    function vpfHash(bytes32 _phenomenonHash, uint _openDate, uint _resolveDate) public pure returns(bytes32) {
        return keccak256(abi.encodePacked(_phenomenonHash, _openDate, _resolveDate));
    }

    function intervalsCount(bytes32 _vpfHash) public view returns(uint) {
        return vpfs[_vpfHash].intervals.length;
    }

    function virtualTradesSummedCount(bytes32 _vpfHash) public view returns(uint) {
        return vpfs[_vpfHash].virtualTradesSummed.length;
    }

    function getIntervals(bytes32 _vpfHash, uint _index) public view returns(int) {
        return vpfs[_vpfHash].intervals[_index];
    }

    function getVirtualTradesSummed(bytes32 _vpfHash, uint _index) public view returns(uint) {
        return vpfs[_vpfHash].virtualTradesSummed[_index];
    }

    modifier onlyValidFactory() {
        require(addressManager.factories(msg.sender));
        _;
    }

    modifier onlyServer() {
        require(msg.sender == serverAddress);
        _;
    }
}

Contract ABI

[{"constant":true,"inputs":[],"name":"openValueGasLimit","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_resolveValueGasLimit","type":"uint256"}],"name":"setResolveValueGasLimit","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"_vpfHash","type":"bytes32"}],"name":"virtualTradesSummedCount","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_vpfHash","type":"bytes32"},{"name":"_tradesTotal","type":"uint256"},{"name":"_virtualTradesSummed","type":"uint256[]"}],"name":"fillTradesInfo","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"","type":"bytes32"}],"name":"vpfs","outputs":[{"name":"phenomenonHash","type":"bytes32"},{"name":"openDate","type":"uint256"},{"name":"closeDate","type":"uint256"},{"name":"resolveDate","type":"uint256"},{"name":"maxBeta","type":"uint256"},{"name":"feePercent","type":"uint256"},{"name":"vpfFactoryInterface","type":"address"},{"name":"tradesTotal","type":"uint256"},{"name":"openValue","type":"uint256"},{"name":"resolveValue","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_vpfHash","type":"bytes32"},{"name":"_time","type":"uint256"},{"name":"_value","type":"uint256"}],"name":"updateValue","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"_openValueGasLimit","type":"uint256"}],"name":"setOpenValueGasLimit","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[],"name":"renounceOwnership","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"_vpfHash","type":"bytes32"}],"name":"intervalsCount","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"resolveValueGasLimit","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_phenomenonHash","type":"bytes32"},{"name":"_openDate","type":"uint256"},{"name":"_closeDate","type":"uint256"},{"name":"_resolveDate","type":"uint256"},{"name":"_maxBeta","type":"uint256"},{"name":"_feePercent","type":"uint256"},{"name":"_intervals","type":"int256[]"}],"name":"addVpf","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"owner","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"_phenomenonHash","type":"bytes32"},{"name":"_openDate","type":"uint256"},{"name":"_resolveDate","type":"uint256"}],"name":"vpfHash","outputs":[{"name":"","type":"bytes32"}],"payable":false,"stateMutability":"pure","type":"function"},{"constant":true,"inputs":[],"name":"serverAddress","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"_vpfHash","type":"bytes32"},{"name":"_index","type":"uint256"}],"name":"getIntervals","outputs":[{"name":"","type":"int256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"_vpfHash","type":"bytes32"},{"name":"_index","type":"uint256"}],"name":"getVirtualTradesSummed","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"inputs":[{"name":"_manager","type":"address"},{"name":"_serverAddress","type":"address"}],"payable":false,"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":false,"name":"hash","type":"bytes32"}],"name":"VpfAdd","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"hash","type":"bytes32"}],"name":"VpfTradesFill","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"hash","type":"bytes32"},{"indexed":false,"name":"value","type":"uint256"}],"name":"VpfOpenValueCheck","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"hash","type":"bytes32"},{"indexed":false,"name":"value","type":"uint256"}],"name":"VpfResolveValueCheck","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"previousOwner","type":"address"}],"name":"OwnershipRenounced","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"previousOwner","type":"address"},{"indexed":true,"name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"}]

Contract Creation Code

608060405262030d40600255620f424060035534801561001e57600080fd5b506040516040806112c283398101604052805160209091015160008054600160a060020a03938416600160a060020a03199182161790915560018054821633179055600480549390921692169190911790556112438061007f6000396000f3006080604052600436106100d75763ffffffff60e060020a6000350416630e0d5c7181146100dc578063257fc8381461010357806329e3ae3d1461011d5780634f0cf7e1146101355780635a510022146101935780635b5d2c8f1461020457806366f99a1114610222578063715018a61461023a5780637d61b9fe1461024f5780637eee22c7146102675780638a4cae0e1461027c5780638da5cb5b146102e9578063c510187e1461031a578063db420fe314610338578063eb49168f1461034d578063f2fde38b14610368578063f69a698214610389575b600080fd5b3480156100e857600080fd5b506100f16103a4565b60408051918252519081900360200190f35b34801561010f57600080fd5b5061011b6004356103aa565b005b34801561012957600080fd5b506100f16004356103c6565b34801561014157600080fd5b50604080516020600460443581810135838102808601850190965280855261011b9583359560248035963696956064959394920192918291850190849080828437509497506103db9650505050505050565b34801561019f57600080fd5b506101ab60043561047a565b604080519a8b5260208b0199909952898901979097526060890195909552608088019390935260a0870191909152600160a060020a031660c086015260e085015261010084015261012083015251908190036101400190f35b34801561021057600080fd5b5061011b6004356024356044356104d6565b34801561022e57600080fd5b5061011b6004356108c9565b34801561024657600080fd5b5061011b6108e5565b34801561025b57600080fd5b506100f1600435610953565b34801561027357600080fd5b506100f1610968565b34801561028857600080fd5b506040805160c4356004818101356020818102858101820190965281855261011b95833595602480359660443596606435966084359660a435963696939560e4950192918291908501908490808284375094975061096e9650505050505050565b3480156102f557600080fd5b506102fe611013565b60408051600160a060020a039092168252519081900360200190f35b34801561032657600080fd5b506100f1600435602435604435611022565b34801561034457600080fd5b506102fe6110b2565b34801561035957600080fd5b506100f16004356024356110c1565b34801561037457600080fd5b5061011b600160a060020a03600435166110f1565b34801561039557600080fd5b506100f1600435602435611114565b60025481565b600154600160a060020a031633146103c157600080fd5b600355565b60009081526005602052604090206009015490565b600454600090600160a060020a031633146103f557600080fd5b506000838152600560205260408120600181015490911061041557600080fd5b60088101541561042457600080fd5b60088101839055815161044090600983019060208501906111af565b506040805185815290517fec8583e56acc4d840988ceecf83e83ef58262b42228f1271fbdc4bc865f5d3da9181900360200190a150505050565b6005602081905260009182526040909120805460018201546002830154600384015460048501549585015460078601546008870154600a880154600b909801549698959794969395949293600160a060020a039092169290918a565b60008060009054906101000a9004600160a060020a0316600160a060020a0316637dc0d1d06040518163ffffffff1660e060020a028152600401602060405180830381600087803b15801561052a57600080fd5b505af115801561053e573d6000803e3d6000fd5b505050506040513d602081101561055457600080fd5b5051600160a060020a0316331461056a57600080fd5b506000838152600560205260409020600181015483148061058e5750806003015483145b151561062157604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603560248201527f54696d65206f66207265717565737420646f6573206e6f74206d61746368206f60448201527f70656e44617465206e6f7220636865636b446174650000000000000000000000606482015290519081900360840190fd5b806001015483141561067457600a8101829055604080518581526020810184905281517fe59193738628cba6f81e7c9262c9cc3b29351379aa9e19f4cd58151c02b9d265929181900390910190a16108c3565b600b8101829055604080518581526020810184905281517f42bb13414a67de904386347019689beffeb699f9344ca100eff54ba44427cbff929181900390910190a18060070160009054906101000a9004600160a060020a0316600160a060020a031663b187bd266040518163ffffffff1660e060020a028152600401602060405180830381600087803b15801561070b57600080fd5b505af115801561071f573d6000803e3d6000fd5b505050506040513d602081101561073557600080fd5b505115801561085057506000809054906101000a9004600160a060020a0316600160a060020a0316631ed6ea6d6040518163ffffffff1660e060020a028152600401602060405180830381600087803b15801561079157600080fd5b505af11580156107a5573d6000803e3d6000fd5b505050506040513d60208110156107bb57600080fd5b50518154604080517f0610e037000000000000000000000000000000000000000000000000000000008152600481019290925251600160a060020a0390921691630610e037916024808201926020929091908290030181600087803b15801561082357600080fd5b505af1158015610837573d6000803e3d6000fd5b505050506040513d602081101561084d57600080fd5b50515b156108c3578060070160009054906101000a9004600160a060020a0316600160a060020a031663aad5632a6040518163ffffffff1660e060020a028152600401600060405180830381600087803b1580156108aa57600080fd5b505af11580156108be573d6000803e3d6000fd5b505050505b50505050565b600154600160a060020a031633146108e057600080fd5b600255565b600154600160a060020a031633146108fc57600080fd5b600154604051600160a060020a03909116907ff8df31144d9c2f0f6b59d69b8b98abd5459d07f2742c4df920b25aae33c6482090600090a26001805473ffffffffffffffffffffffffffffffffffffffff19169055565b60009081526005602052604090206006015490565b60035481565b60008054604080517ffab5268900000000000000000000000000000000000000000000000000000000815233600482015290518392600160a060020a03169163fab5268991602480830192602092919082900301818787803b1580156109d357600080fd5b505af11580156109e7573d6000803e3d6000fd5b505050506040513d60208110156109fd57600080fd5b50511515610a0a57600080fd5b6000809054906101000a9004600160a060020a0316600160a060020a0316631ed6ea6d6040518163ffffffff1660e060020a028152600401602060405180830381600087803b158015610a5c57600080fd5b505af1158015610a70573d6000803e3d6000fd5b505050506040513d6020811015610a8657600080fd5b5051604080517f0610e037000000000000000000000000000000000000000000000000000000008152600481018c90529051600160a060020a0390921691630610e037916024808201926020929091908290030181600087803b158015610aec57600080fd5b505af1158015610b00573d6000803e3d6000fd5b505050506040513d6020811015610b1657600080fd5b50511515610b2357600080fd5b610b2e898988611022565b9150610180604051908101604052808a60001916815260200189815260200188815260200187815260200186815260200185815260200184815260200133600160a060020a03168152602001600081526020016000604051908082528060200260200182016040528015610bac578160200160208202803883390190505b50815260006020808301829052604092830182905285825260058082529183902084518155848201516001820155928401516002840155606084015160038401556080840151600484015560a08401519183019190915560c08301518051610c1a92600685019201906111af565b5060e082015160078201805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0390921691909117905561010082015160088201556101208201518051610c759160098401916020909101906111af565b50610140820151600a82015561016090910151600b909101556040805183815290517fc06c963faccb83448bc49da27b325ddf9779fe8dd25dae37033d2ddfad5a23b59181900360200190a16000809054906101000a9004600160a060020a0316600160a060020a0316631ed6ea6d6040518163ffffffff1660e060020a028152600401602060405180830381600087803b158015610d1357600080fd5b505af1158015610d27573d6000803e3d6000fd5b505050506040513d6020811015610d3d57600080fd5b5051604080517ff95440ba000000000000000000000000000000000000000000000000000000008152600481018c90529051600160a060020a039092169163f95440ba916024808201926020929091908290030181600087803b158015610da357600080fd5b505af1158015610db7573d6000803e3d6000fd5b505050506040513d6020811015610dcd57600080fd5b505160008054604080517f7dc0d1d00000000000000000000000000000000000000000000000000000000081529051939450600160a060020a0390911692637dc0d1d092600480840193602093929083900390910190829087803b158015610e3457600080fd5b505af1158015610e48573d6000803e3d6000fd5b505050506040513d6020811015610e5e57600080fd5b5051600254604080517f45ff8fde00000000000000000000000000000000000000000000000000000000815260048101869052602481018c905260ff85166044820152606481019290925251600160a060020a03909216916345ff8fde9160848082019260009290919082900301818387803b158015610edd57600080fd5b505af1158015610ef1573d6000803e3d6000fd5b505050506000809054906101000a9004600160a060020a0316600160a060020a0316637dc0d1d06040518163ffffffff1660e060020a028152600401602060405180830381600087803b158015610f4757600080fd5b505af1158015610f5b573d6000803e3d6000fd5b505050506040513d6020811015610f7157600080fd5b5051600354604080517f45ff8fde00000000000000000000000000000000000000000000000000000000815260048101869052602481018a905260ff85166044820152606481019290925251600160a060020a03909216916345ff8fde9160848082019260009290919082900301818387803b158015610ff057600080fd5b505af1158015611004573d6000803e3d6000fd5b50505050505050505050505050565b600154600160a060020a031681565b6040805160208082018690528183018590526060808301859052835180840390910181526080909201928390528151600093918291908401908083835b6020831061107e5780518252601f19909201916020918201910161105f565b5181516020939093036101000a60001901801990911692169190911790526040519201829003909120979650505050505050565b600454600160a060020a031681565b60008281526005602052604081206006018054839081106110de57fe5b9060005260206000200154905092915050565b600154600160a060020a0316331461110857600080fd5b61111181611131565b50565b60008281526005602052604081206009018054839081106110de57fe5b600160a060020a038116151561114657600080fd5b600154604051600160a060020a038084169216907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a36001805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0392909216919091179055565b8280548282559060005260206000209081019282156111ea579160200282015b828111156111ea5782518255916020019190600101906111cf565b506111f69291506111fa565b5090565b61121491905b808211156111f65760008155600101611200565b905600a165627a7a72305820e1ce8b4ac73fb3e97189b9f0f5e73d115be1fe2a675aaf4f080ca482132e93f900290000000000000000000000004d0e3e6beec9e37eed69218f5e9d2b570dcbf8730000000000000000000000006bf0b47025f29944b1df31251a9ddc95d7949410

Swarm Source

bzzr://e1ce8b4ac73fb3e97189b9f0f5e73d115be1fe2a675aaf4f080ca482132e93f9
Block Age Transaction Difficulty GasUsed Reward
Block Age Uncle Number Difficulty GasUsed Reward