{
  "contractName": "MarketContract",
  "abi": [
    {
      "constant": true,
      "inputs": [],
      "name": "lastPrice",
      "outputs": [
        {
          "name": "",
          "type": "uint256"
        }
      ],
      "payable": false,
      "stateMutability": "view",
      "type": "function"
    },
    {
      "constant": true,
      "inputs": [],
      "name": "LONG_POSITION_TOKEN",
      "outputs": [
        {
          "name": "",
          "type": "address"
        }
      ],
      "payable": false,
      "stateMutability": "view",
      "type": "function"
    },
    {
      "constant": true,
      "inputs": [],
      "name": "PRICE_DECIMAL_PLACES",
      "outputs": [
        {
          "name": "",
          "type": "uint256"
        }
      ],
      "payable": false,
      "stateMutability": "view",
      "type": "function"
    },
    {
      "constant": true,
      "inputs": [],
      "name": "COLLATERAL_TOKEN_ADDRESS",
      "outputs": [
        {
          "name": "",
          "type": "address"
        }
      ],
      "payable": false,
      "stateMutability": "view",
      "type": "function"
    },
    {
      "constant": true,
      "inputs": [],
      "name": "isSettled",
      "outputs": [
        {
          "name": "",
          "type": "bool"
        }
      ],
      "payable": false,
      "stateMutability": "view",
      "type": "function"
    },
    {
      "constant": true,
      "inputs": [],
      "name": "SETTLEMENT_DELAY",
      "outputs": [
        {
          "name": "",
          "type": "uint256"
        }
      ],
      "payable": false,
      "stateMutability": "view",
      "type": "function"
    },
    {
      "constant": true,
      "inputs": [],
      "name": "SHORT_POSITION_TOKEN",
      "outputs": [
        {
          "name": "",
          "type": "address"
        }
      ],
      "payable": false,
      "stateMutability": "view",
      "type": "function"
    },
    {
      "constant": true,
      "inputs": [],
      "name": "COLLATERAL_TOKEN_FEE_PER_UNIT",
      "outputs": [
        {
          "name": "",
          "type": "uint256"
        }
      ],
      "payable": false,
      "stateMutability": "view",
      "type": "function"
    },
    {
      "constant": true,
      "inputs": [],
      "name": "CONTRACT_NAME",
      "outputs": [
        {
          "name": "",
          "type": "string"
        }
      ],
      "payable": false,
      "stateMutability": "view",
      "type": "function"
    },
    {
      "constant": false,
      "inputs": [],
      "name": "renounceOwnership",
      "outputs": [],
      "payable": false,
      "stateMutability": "nonpayable",
      "type": "function"
    },
    {
      "constant": true,
      "inputs": [],
      "name": "settlementTimeStamp",
      "outputs": [
        {
          "name": "",
          "type": "uint256"
        }
      ],
      "payable": false,
      "stateMutability": "view",
      "type": "function"
    },
    {
      "constant": true,
      "inputs": [],
      "name": "owner",
      "outputs": [
        {
          "name": "",
          "type": "address"
        }
      ],
      "payable": false,
      "stateMutability": "view",
      "type": "function"
    },
    {
      "constant": true,
      "inputs": [],
      "name": "isOwner",
      "outputs": [
        {
          "name": "",
          "type": "bool"
        }
      ],
      "payable": false,
      "stateMutability": "view",
      "type": "function"
    },
    {
      "constant": true,
      "inputs": [],
      "name": "PRICE_CAP",
      "outputs": [
        {
          "name": "",
          "type": "uint256"
        }
      ],
      "payable": false,
      "stateMutability": "view",
      "type": "function"
    },
    {
      "constant": true,
      "inputs": [],
      "name": "EXPIRATION",
      "outputs": [
        {
          "name": "",
          "type": "uint256"
        }
      ],
      "payable": false,
      "stateMutability": "view",
      "type": "function"
    },
    {
      "constant": true,
      "inputs": [],
      "name": "PRICE_FLOOR",
      "outputs": [
        {
          "name": "",
          "type": "uint256"
        }
      ],
      "payable": false,
      "stateMutability": "view",
      "type": "function"
    },
    {
      "constant": true,
      "inputs": [],
      "name": "QTY_MULTIPLIER",
      "outputs": [
        {
          "name": "",
          "type": "uint256"
        }
      ],
      "payable": false,
      "stateMutability": "view",
      "type": "function"
    },
    {
      "constant": true,
      "inputs": [],
      "name": "MKT_TOKEN_FEE_PER_UNIT",
      "outputs": [
        {
          "name": "",
          "type": "uint256"
        }
      ],
      "payable": false,
      "stateMutability": "view",
      "type": "function"
    },
    {
      "constant": true,
      "inputs": [],
      "name": "COLLATERAL_PER_UNIT",
      "outputs": [
        {
          "name": "",
          "type": "uint256"
        }
      ],
      "payable": false,
      "stateMutability": "view",
      "type": "function"
    },
    {
      "constant": true,
      "inputs": [],
      "name": "COLLATERAL_POOL_ADDRESS",
      "outputs": [
        {
          "name": "",
          "type": "address"
        }
      ],
      "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": "settlementPrice",
      "outputs": [
        {
          "name": "",
          "type": "uint256"
        }
      ],
      "payable": false,
      "stateMutability": "view",
      "type": "function"
    },
    {
      "inputs": [
        {
          "name": "contractNames",
          "type": "bytes32[3]"
        },
        {
          "name": "baseAddresses",
          "type": "address[3]"
        },
        {
          "name": "contractSpecs",
          "type": "uint256[7]"
        }
      ],
      "payable": false,
      "stateMutability": "nonpayable",
      "type": "constructor"
    },
    {
      "anonymous": false,
      "inputs": [
        {
          "indexed": false,
          "name": "price",
          "type": "uint256"
        }
      ],
      "name": "UpdatedLastPrice",
      "type": "event"
    },
    {
      "anonymous": false,
      "inputs": [
        {
          "indexed": false,
          "name": "settlePrice",
          "type": "uint256"
        }
      ],
      "name": "ContractSettled",
      "type": "event"
    },
    {
      "anonymous": false,
      "inputs": [
        {
          "indexed": true,
          "name": "previousOwner",
          "type": "address"
        },
        {
          "indexed": true,
          "name": "newOwner",
          "type": "address"
        }
      ],
      "name": "OwnershipTransferred",
      "type": "event"
    },
    {
      "constant": false,
      "inputs": [
        {
          "name": "qtyToMint",
          "type": "uint256"
        },
        {
          "name": "minter",
          "type": "address"
        }
      ],
      "name": "mintPositionTokens",
      "outputs": [],
      "payable": false,
      "stateMutability": "nonpayable",
      "type": "function"
    },
    {
      "constant": false,
      "inputs": [
        {
          "name": "qtyToRedeem",
          "type": "uint256"
        },
        {
          "name": "redeemer",
          "type": "address"
        }
      ],
      "name": "redeemLongToken",
      "outputs": [],
      "payable": false,
      "stateMutability": "nonpayable",
      "type": "function"
    },
    {
      "constant": false,
      "inputs": [
        {
          "name": "qtyToRedeem",
          "type": "uint256"
        },
        {
          "name": "redeemer",
          "type": "address"
        }
      ],
      "name": "redeemShortToken",
      "outputs": [],
      "payable": false,
      "stateMutability": "nonpayable",
      "type": "function"
    },
    {
      "constant": true,
      "inputs": [],
      "name": "isPostSettlementDelay",
      "outputs": [
        {
          "name": "",
          "type": "bool"
        }
      ],
      "payable": false,
      "stateMutability": "view",
      "type": "function"
    }
  ],
  "metadata": "{\"compiler\":{\"version\":\"0.5.2+commit.1df8f40c\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":true,\"inputs\":[],\"name\":\"lastPrice\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"LONG_POSITION_TOKEN\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"PRICE_DECIMAL_PLACES\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"COLLATERAL_TOKEN_ADDRESS\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"isSettled\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"SETTLEMENT_DELAY\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"SHORT_POSITION_TOKEN\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"COLLATERAL_TOKEN_FEE_PER_UNIT\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"CONTRACT_NAME\",\"outputs\":[{\"name\":\"\",\"type\":\"string\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"qtyToRedeem\",\"type\":\"uint256\"},{\"name\":\"redeemer\",\"type\":\"address\"}],\"name\":\"redeemShortToken\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[],\"name\":\"renounceOwnership\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"settlementTimeStamp\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"isOwner\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"PRICE_CAP\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"EXPIRATION\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"isPostSettlementDelay\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"qtyToRedeem\",\"type\":\"uint256\"},{\"name\":\"redeemer\",\"type\":\"address\"}],\"name\":\"redeemLongToken\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"PRICE_FLOOR\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"QTY_MULTIPLIER\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"qtyToMint\",\"type\":\"uint256\"},{\"name\":\"minter\",\"type\":\"address\"}],\"name\":\"mintPositionTokens\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"MKT_TOKEN_FEE_PER_UNIT\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"COLLATERAL_PER_UNIT\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"COLLATERAL_POOL_ADDRESS\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"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\":\"settlementPrice\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"name\":\"contractNames\",\"type\":\"bytes32[3]\"},{\"name\":\"baseAddresses\",\"type\":\"address[3]\"},{\"name\":\"contractSpecs\",\"type\":\"uint256[7]\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"name\":\"price\",\"type\":\"uint256\"}],\"name\":\"UpdatedLastPrice\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"name\":\"settlePrice\",\"type\":\"uint256\"}],\"name\":\"ContractSettled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"previousOwner\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"OwnershipTransferred\",\"type\":\"event\"}],\"devdoc\":{\"author\":\"Phil Elsasser <phil@marketprotocol.io>\",\"methods\":{\"constructor\":{\"params\":{\"baseAddresses\":\"array of 2 addresses needed for our contract including:     ownerAddress                    address of the owner of these contracts.     collateralTokenAddress          address of the ERC20 token that will be used for collateral and pricing     collateralPoolAddress           address of our collateral pool contract\",\"contractNames\":\"bytes32 array of names     contractName            name of the market contract     longTokenSymbol         symbol for the long token     shortTokenSymbol        symbol for the short token\",\"contractSpecs\":\"array of unsigned integers including:     floorPrice          minimum tradeable price of this contract, contract enters settlement if breached     capPrice            maximum tradeable price of this contract, contract enters settlement if breached     priceDecimalPlaces  number of decimal places to convert our queried price from a floating point to                         an integer     qtyMultiplier       multiply traded qty by this value from base units of collateral token.     feeInBasisPoints    fee amount in basis points (Collateral token denominated) for minting.     mktFeeInBasisPoints fee amount in basis points (MKT denominated) for minting.     expirationTimeStamp seconds from epoch that this contract expires and enters settlement\"}},\"isOwner()\":{\"return\":\"true if `msg.sender` is the owner of the contract.\"},\"mintPositionTokens(uint256,address)\":{\"params\":{\"minter\":\"address of minter to receive tokens\",\"qtyToMint\":\"qty in base units of how many short and long tokens to mint\"}},\"owner()\":{\"return\":\"the address of the owner.\"},\"redeemLongToken(uint256,address)\":{\"params\":{\"qtyToRedeem\":\"qty in base units of how many tokens to redeem\",\"redeemer\":\"address of person redeeming tokens\"}},\"redeemShortToken(uint256,address)\":{\"params\":{\"qtyToRedeem\":\"qty in base units of how many tokens to redeem\",\"redeemer\":\"address of person redeeming tokens\"}},\"renounceOwnership()\":{\"details\":\"Allows the current owner to relinquish control of the contract. It will not be possible to call the functions with the `onlyOwner` modifier anymore.\"},\"transferOwnership(address)\":{\"details\":\"Allows the current owner to transfer control of the contract to a newOwner.\",\"params\":{\"newOwner\":\"The address to transfer ownership to.\"}}},\"title\":\"MarketContract base contract implement all needed functionality for trading.\"},\"userdoc\":{\"methods\":{\"isPostSettlementDelay()\":{\"notice\":\"checks to see if a contract is settled, and that the settlement delay has passed\"},\"mintPositionTokens(uint256,address)\":{\"notice\":\"called only by our collateral pool to create long and short position tokens\"},\"redeemLongToken(uint256,address)\":{\"notice\":\"called only by our collateral pool to redeem long position tokens\"},\"redeemShortToken(uint256,address)\":{\"notice\":\"called only by our collateral pool to redeem short position tokens\"},\"renounceOwnership()\":{\"notice\":\"Renouncing ownership will leave the contract without an owner, thereby removing any functionality that is only available to the owner.\"}},\"notice\":\"this is the abstract base contract that all contracts should inherit from to implement different oracle solutions.\"}},\"settings\":{\"compilationTarget\":{\"/home/travis/build/MARKETProtocol/MARKETProtocol/contracts/MarketContract.sol\":\"MarketContract\"},\"evmVersion\":\"byzantium\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/home/travis/build/MARKETProtocol/MARKETProtocol/contracts/MarketContract.sol\":{\"keccak256\":\"0xb1e837f17c189abdf5e9f699be068f07d45618df3a6adece0d4a2f78879428be\",\"urls\":[\"bzzr://51deacf4c6dfbabc62017f9c407ce55002c3906e16b810ad9033eb8df6633f3f\"]},\"/home/travis/build/MARKETProtocol/MARKETProtocol/contracts/libraries/MathLib.sol\":{\"keccak256\":\"0x28e7ed8ea6e300e4d0dbf0e63b2414ba71bc1596b7142690c1bf4016e313abee\",\"urls\":[\"bzzr://6bb2953cfd96de25e614d77e8a4793a8bc11f9eae0d2d0fb9614488bca7e1754\"]},\"/home/travis/build/MARKETProtocol/MARKETProtocol/contracts/libraries/StringLib.sol\":{\"keccak256\":\"0xa1d7d76809600493055bdb04692a775fde71142a921f994568beb1fdb42a92c7\",\"urls\":[\"bzzr://dcc475bb3f21803b7d5fba4157f07c5fc642ea9a976eb118bac74a1cb0b91f4f\"]},\"/home/travis/build/MARKETProtocol/MARKETProtocol/contracts/tokens/PositionToken.sol\":{\"keccak256\":\"0xa1b6986878eedeb5014268a4257b0918473c348f6f39c1558bced6dcf0268f01\",\"urls\":[\"bzzr://9af5870494a1ac62401d92713525808c132a34e11f4dc6aa73f4174ada0201e8\"]},\"openzeppelin-solidity/contracts/math/SafeMath.sol\":{\"keccak256\":\"0xc2a200a877c4a9b2475c246c54ffecc69ffde3e11af83319c63c2dc5458bac80\",\"urls\":[\"bzzr://c8876e2c39b60f155d748d71d715c8f3903fae5a405ac599adcb6ad2f9a583f9\"]},\"openzeppelin-solidity/contracts/ownership/Ownable.sol\":{\"keccak256\":\"0xcb16adc00dcf0d75e0bdf94379f4d5a6d74dca7c74e4183b94e15721159f8a30\",\"urls\":[\"bzzr://b81e03f7203cd628cfed19255911a04a05e8670d248afb48a7b067dd03b4ff55\"]},\"openzeppelin-solidity/contracts/token/ERC20/ERC20.sol\":{\"keccak256\":\"0x3dceb7e4aa237a56111c13f77d7efadeceda7271d62bfac94ac79afab7c1f411\",\"urls\":[\"bzzr://2f34152a5bec385352002c31bc89f5e9935f628f1923ccea45c2281e0084a4db\"]},\"openzeppelin-solidity/contracts/token/ERC20/IERC20.sol\":{\"keccak256\":\"0x59e7df16169a498cb8837963b2f5461d88e63bd1eb6c7d58b814d76b84ccbe61\",\"urls\":[\"bzzr://e572c9c4e02e37349702451bf3b5dcbbc86a19da5a51695b5b3e1bfe1e7825dc\"]}},\"version\":1}",
  "bytecode": "0x608060405262015180600c556000601260006101000a81548160ff0219169083151502179055503480156200003357600080fd5b506040516101a0806200385383398101806040526101a08110156200005757600080fd5b8101908091908260600191908260600191905050336000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055506000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a38060006007811015156200013757fe5b60200201516005819055508060016007811015156200015257fe5b6020020151600481905550600554600454111515620001bd576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018062003806602a913960400191505060405180910390fd5b806002600781101515620001cd57fe5b6020020151600681905550806003600781101515620001e857fe5b60200201516007819055508060066007811015156200020357fe5b6020020151600b8190555042600b5411151562000288576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f45585049524154494f4e206d75737420626520696e207468652066757475726581525060200191505060405180910390fd5b60006007541415151562000304576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601a8152602001807f5154595f4d554c5449504c4945522063616e6e6f74206265203000000000000081525060200191505060405180910390fd5b8160016003811015156200031457fe5b6020020151600260006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508160026003811015156200036957fe5b6020020151600360006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550620003d5600554600454600754620007766401000000000262001048176401000000009004565b60088190555062000417600554600454600754846004600781101515620003f857fe5b6020020151620007b66401000000000262001066176401000000009004565b600981905550620004596005546004546007548460056007811015156200043a57fe5b6020020151620007b66401000000000262001066176401000000009004565b600a81905550620004928360006003811015156200047357fe5b60200201516200083164010000000002620010ac176401000000009004565b60019080519060200190620004a992919062000c52565b506000620004df846001600381101515620004c057fe5b60200201516200083164010000000002620010ac176401000000009004565b60006001811115620004ed57fe5b620004f762000cd9565b8080602001806020018460ff1660ff168152602001838103835260238152602001806200383060239139604001838103825285818151815260200191508051906020019080838360005b838110156200055e57808201518184015260208101905062000541565b50505050905090810190601f1680156200058c5780820380516001836020036101000a031916815260200191505b50945050505050604051809103906000f080158015620005b0573d6000803e3d6000fd5b5090506000620005e8856002600381101515620005c957fe5b60200201516200083164010000000002620010ac176401000000009004565b600180811115620005f557fe5b620005ff62000cd9565b8080602001806020018460ff1660ff16815260200183810383526024815260200180620037e260249139604001838103825285818151815260200191508051906020019080838360005b838110156200066657808201518184015260208101905062000649565b50505050905090810190601f168015620006945780820380516001836020036101000a031916815260200191505b50945050505050604051809103906000f080158015620006b8573d6000803e3d6000fd5b50905081600d60006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555080600e60006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055506200076b8460006003811015156200075157fe5b602002015162000902640100000000026401000000009004565b505050505062000d12565b6000620007ad62000797848662000944640100000000026401000000009004565b83620009ca640100000000026401000000009004565b90509392505050565b6000806002620007d6868862000a75640100000000026401000000009004565b811515620007e057fe5b0490506127106200081b620008058387620009ca640100000000026401000000009004565b85620009ca640100000000026401000000009004565b8115156200082557fe5b04915050949350505050565b60608060206040519080825280601f01601f191660200182016040528015620008695781602001600182028038833980820191505090505b50905060005b6020811015620008f85783816020811015156200088857fe5b1a7f0100000000000000000000000000000000000000000000000000000000000000028282815181101515620008ba57fe5b9060200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535080806001019150506200086f565b5080915050919050565b6200091b62000b00640100000000026401000000009004565b15156200092757600080fd5b620009418162000b57640100000000026401000000009004565b50565b6000828211151515620009bf576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601d8152602001807f4d6174684c69623a207375627472616374696f6e206f766572666c6f7700000081525060200191505060405180910390fd5b818303905092915050565b600080831415620009df576000905062000a6f565b60008284029050828482811515620009f357fe5b0414151562000a6a576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4d6174684c69623a206d756c7469706c69636174696f6e206f766572666c6f7781525060200191505060405180910390fd5b809150505b92915050565b600080828401905083811015151562000af6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601a8152602001807f4d6174684c69623a206164646974696f6e206f766572666c6f7700000000000081525060200191505060405180910390fd5b8091505092915050565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614905090565b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161415151562000b9457600080fd5b8073ffffffffffffffffffffffffffffffffffffffff166000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a3806000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f1062000c9557805160ff191683800117855562000cc6565b8280016001018555821562000cc6579182015b8281111562000cc557825182559160200191906001019062000ca8565b5b50905062000cd5919062000cea565b5090565b60405161174080620020a283390190565b62000d0f91905b8082111562000d0b57600081600090555060010162000cf1565b5090565b90565b6113808062000d226000396000f3fe608060405234801561001057600080fd5b50600436106101ab576000357c0100000000000000000000000000000000000000000000000000000000900480638f32d59b116100fb578063ca361d67116100b4578063e158e02d1161008e578063e158e02d146105e1578063eaafb4fa146105ff578063f2fde38b14610649578063f348e8b21461068d576101ab565b8063ca361d6714610557578063cabd583414610575578063db3fa771146105c3576101ab565b80638f32d59b1461046b578063b5471dee1461048d578063bb4b5734146104ab578063bd220dae146104c9578063c25c4444146104eb578063c32b1dfa14610539576101ab565b80635b3f1e3f116101685780636d359467116101425780636d359467146103ab578063715018a6146103f957806386aa7cdc146104035780638da5cb5b14610421576101ab565b80635b3f1e3f146102c05780635c7c70591461030a578063614d08f814610328576101ab565b8063053f14da146101b057806322d1c35e146101ce5780632fed1b0014610218578063323bb775146102365780633270bb5b1461028057806357d1ba25146102a2575b600080fd5b6101b86106ab565b6040518082815260200191505060405180910390f35b6101d66106b1565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b6102206106d7565b6040518082815260200191505060405180910390f35b61023e6106dd565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b610288610703565b604051808215151515815260200191505060405180910390f35b6102aa610716565b6040518082815260200191505060405180910390f35b6102c861071c565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b610312610742565b6040518082815260200191505060405180910390f35b610330610748565b6040518080602001828103825283818151815260200191508051906020019080838360005b83811015610370578082015181840152602081019050610355565b50505050905090810190601f16801561039d5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6103f7600480360360408110156103c157600080fd5b8101908080359060200190929190803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506107e6565b005b61040161096f565b005b61040b610a41565b6040518082815260200191505060405180910390f35b610429610a47565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b610473610a70565b604051808215151515815260200191505060405180910390f35b610495610ac7565b6040518082815260200191505060405180910390f35b6104b3610acd565b6040518082815260200191505060405180910390f35b6104d1610ad3565b604051808215151515815260200191505060405180910390f35b6105376004803603604081101561050157600080fd5b8101908080359060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610afc565b005b610541610c85565b6040518082815260200191505060405180910390f35b61055f610c8b565b6040518082815260200191505060405180910390f35b6105c16004803603604081101561058b57600080fd5b8101908080359060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610c91565b005b6105cb610ef7565b6040518082815260200191505060405180910390f35b6105e9610efd565b6040518082815260200191505060405180910390f35b610607610f03565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b61068b6004803603602081101561065f57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610f29565b005b610695610f48565b6040518082815260200191505060405180910390f35b600f5481565b600d60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b60065481565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b601260009054906101000a900460ff1681565b600c5481565b600e60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b60095481565b60018054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156107de5780601f106107b3576101008083540402835291602001916107de565b820191906000526020600020905b8154815290600101906020018083116107c157829003601f168201915b505050505081565b600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614151561088e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602681526020018061132f6026913960400191505060405180910390fd5b600e60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663c3501ff683836040518363ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401808381526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200192505050600060405180830381600087803b15801561095357600080fd5b505af1158015610967573d6000803e3d6000fd5b505050505050565b610977610a70565b151561098257600080fd5b600073ffffffffffffffffffffffffffffffffffffffff166000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a360008060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550565b60115481565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614905090565b60045481565b600b5481565b6000601260009054906101000a900460ff168015610af75750600c54601154014210155b905090565b600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16141515610ba4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602681526020018061132f6026913960400191505060405180910390fd5b600d60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663c3501ff683836040518363ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401808381526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200192505050600060405180830381600087803b158015610c6957600080fd5b505af1158015610c7d573d6000803e3d6000fd5b505050505050565b60055481565b60075481565b600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16141515610d39576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602681526020018061132f6026913960400191505060405180910390fd5b600d60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16637251cd0283836040518363ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401808381526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200192505050600060405180830381600087803b158015610dfe57600080fd5b505af1158015610e12573d6000803e3d6000fd5b50505050600e60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16637251cd0283836040518363ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401808381526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200192505050600060405180830381600087803b158015610edb57600080fd5b505af1158015610eef573d6000803e3d6000fd5b505050505050565b600a5481565b60085481565b600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b610f31610a70565b1515610f3c57600080fd5b610f4581610f4e565b50565b60105481565b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1614151515610f8a57600080fd5b8073ffffffffffffffffffffffffffffffffffffffff166000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a3806000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b600061105d6110578486611178565b836111fd565b90509392505050565b600080600261107586886112a4565b81151561107e57fe5b04905061271061109761109183876111fd565b856111fd565b8115156110a057fe5b04915050949350505050565b60608060206040519080825280601f01601f1916602001820160405280156110e35781602001600182028038833980820191505090505b50905060005b602081101561116e57838160208110151561110057fe5b1a7f010000000000000000000000000000000000000000000000000000000000000002828281518110151561113157fe5b9060200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535080806001019150506110e9565b5080915050919050565b60008282111515156111f2576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601d8152602001807f4d6174684c69623a207375627472616374696f6e206f766572666c6f7700000081525060200191505060405180910390fd5b818303905092915050565b600080831415611210576000905061129e565b6000828402905082848281151561122357fe5b04141515611299576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4d6174684c69623a206d756c7469706c69636174696f6e206f766572666c6f7781525060200191505060405180910390fd5b809150505b92915050565b6000808284019050838110151515611324576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601a8152602001807f4d6174684c69623a206164646974696f6e206f766572666c6f7700000000000081525060200191505060405180910390fd5b809150509291505056fe4f6e6c792063616c6c61626c652066726f6d2074686520636f6c6c61746572616c20706f6f6ca165627a7a72305820317283b72aa2bd300986621cceba2349768c35ec59958e2c24fd9067aa5b0824002960806040523480156200001157600080fd5b506040516200174038038062001740833981018060405260608110156200003757600080fd5b8101908080516401000000008111156200005057600080fd5b828101905060208101848111156200006757600080fd5b81518560018202830111640100000000821117156200008557600080fd5b50509291906020018051640100000000811115620000a257600080fd5b82810190506020810184811115620000b957600080fd5b8151856001820283011164010000000082111715620000d757600080fd5b50509291906020018051906020019092919050505033600360006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a38260049080519060200190620001c292919062000234565b508160059080519060200190620001db92919062000234565b506005600660006101000a81548160ff021916908360ff1602179055508060ff1660018111156200020857fe5b600660016101000a81548160ff021916908360018111156200022657fe5b0217905550505050620002e3565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f106200027757805160ff1916838001178555620002a8565b82800160010185558215620002a8579182015b82811115620002a75782518255916020019190600101906200028a565b5b509050620002b79190620002bb565b5090565b620002e091905b80821115620002dc576000816000905550600101620002c2565b5090565b90565b61144d80620002f36000396000f3fe608060405234801561001057600080fd5b5060043610610133576000357c0100000000000000000000000000000000000000000000000000000000900480638da5cb5b116100bf578063a9059cbb1161008e578063a9059cbb14610554578063b003b127146105ba578063c3501ff6146105e6578063dd62ed3e14610634578063f2fde38b146106ac57610133565b80638da5cb5b146103ff5780638f32d59b1461044957806395d89b411461046b578063a457c2d7146104ee57610133565b8063313ce56711610106578063313ce567146102c557806339509351146102e957806370a082311461034f578063715018a6146103a75780637251cd02146103b157610133565b806306fdde0314610138578063095ea7b3146101bb57806318160ddd1461022157806323b872dd1461023f575b600080fd5b6101406106f0565b6040518080602001828103825283818151815260200191508051906020019080838360005b83811015610180578082015181840152602081019050610165565b50505050905090810190601f1680156101ad5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b610207600480360360408110156101d157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061078e565b604051808215151515815260200191505060405180910390f35b6102296107a5565b6040518082815260200191505060405180910390f35b6102ab6004803603606081101561025557600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506107af565b604051808215151515815260200191505060405180910390f35b6102cd610860565b604051808260ff1660ff16815260200191505060405180910390f35b610335600480360360408110156102ff57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610873565b604051808215151515815260200191505060405180910390f35b6103916004803603602081101561036557600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610918565b6040518082815260200191505060405180910390f35b6103af610960565b005b6103fd600480360360408110156103c757600080fd5b8101908080359060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610a34565b005b610407610a55565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b610451610a7f565b604051808215151515815260200191505060405180910390f35b610473610ad7565b6040518080602001828103825283818151815260200191508051906020019080838360005b838110156104b3578082015181840152602081019050610498565b50505050905090810190601f1680156104e05780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b61053a6004803603604081101561050457600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610b75565b604051808215151515815260200191505060405180910390f35b6105a06004803603604081101561056a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610c1a565b604051808215151515815260200191505060405180910390f35b6105c2610c31565b604051808260018111156105d257fe5b60ff16815260200191505060405180910390f35b610632600480360360408110156105fc57600080fd5b8101908080359060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610c44565b005b6106966004803603604081101561064a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610c65565b6040518082815260200191505060405180910390f35b6106ee600480360360208110156106c257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610cec565b005b60048054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156107865780601f1061075b57610100808354040283529160200191610786565b820191906000526020600020905b81548152906001019060200180831161076957829003601f168201915b505050505081565b600061079b338484610d0b565b6001905092915050565b6000600254905090565b60006107bc848484610e6e565b610855843361085085600160008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205461103a90919063ffffffff16565b610d0b565b600190509392505050565b600660009054906101000a900460ff1681565b600061090e338461090985600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205461105c90919063ffffffff16565b610d0b565b6001905092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b610968610a7f565b151561097357600080fd5b600073ffffffffffffffffffffffffffffffffffffffff16600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a36000600360006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550565b610a3c610a7f565b1515610a4757600080fd5b610a51818361107d565b5050565b6000600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b6000600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614905090565b60058054600181600116156101000203166002900480601f016020809104026020016040519081016040528092919081815260200182805460018160011615610100020316600290048015610b6d5780601f10610b4257610100808354040283529160200191610b6d565b820191906000526020600020905b815481529060010190602001808311610b5057829003601f168201915b505050505081565b6000610c103384610c0b85600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205461103a90919063ffffffff16565b610d0b565b6001905092915050565b6000610c27338484610e6e565b6001905092915050565b600660019054906101000a900460ff1681565b610c4c610a7f565b1515610c5757600080fd5b610c6181836111d1565b5050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b610cf4610a7f565b1515610cff57600080fd5b610d0881611325565b50565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614151515610d4757600080fd5b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff1614151515610d8357600080fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614151515610eaa57600080fd5b610efb816000808673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205461103a90919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610f8e816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205461105c90919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b600082821115151561104b57600080fd5b600082840390508091505092915050565b600080828401905083811015151561107357600080fd5b8091505092915050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16141515156110b957600080fd5b6110ce8160025461105c90919063ffffffff16565b600281905550611125816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205461105c90919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a35050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415151561120d57600080fd5b6112228160025461103a90919063ffffffff16565b600281905550611279816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205461103a90919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a35050565b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161415151561136157600080fd5b8073ffffffffffffffffffffffffffffffffffffffff16600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a380600360006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055505056fea165627a7a72305820f78463906e10274fd094b6c616e88b0a499190ef7ae9e61cb7c2d548533b5a8400294d41524b45542050726f746f636f6c2053686f727420506f736974696f6e20546f6b656e50524943455f434150206d7573742062652067726561746572207468616e2050524943455f464c4f4f524d41524b45542050726f746f636f6c204c6f6e6720506f736974696f6e20546f6b656e",
  "deployedBytecode": "0x608060405234801561001057600080fd5b50600436106101ab576000357c0100000000000000000000000000000000000000000000000000000000900480638f32d59b116100fb578063ca361d67116100b4578063e158e02d1161008e578063e158e02d146105e1578063eaafb4fa146105ff578063f2fde38b14610649578063f348e8b21461068d576101ab565b8063ca361d6714610557578063cabd583414610575578063db3fa771146105c3576101ab565b80638f32d59b1461046b578063b5471dee1461048d578063bb4b5734146104ab578063bd220dae146104c9578063c25c4444146104eb578063c32b1dfa14610539576101ab565b80635b3f1e3f116101685780636d359467116101425780636d359467146103ab578063715018a6146103f957806386aa7cdc146104035780638da5cb5b14610421576101ab565b80635b3f1e3f146102c05780635c7c70591461030a578063614d08f814610328576101ab565b8063053f14da146101b057806322d1c35e146101ce5780632fed1b0014610218578063323bb775146102365780633270bb5b1461028057806357d1ba25146102a2575b600080fd5b6101b86106ab565b6040518082815260200191505060405180910390f35b6101d66106b1565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b6102206106d7565b6040518082815260200191505060405180910390f35b61023e6106dd565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b610288610703565b604051808215151515815260200191505060405180910390f35b6102aa610716565b6040518082815260200191505060405180910390f35b6102c861071c565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b610312610742565b6040518082815260200191505060405180910390f35b610330610748565b6040518080602001828103825283818151815260200191508051906020019080838360005b83811015610370578082015181840152602081019050610355565b50505050905090810190601f16801561039d5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6103f7600480360360408110156103c157600080fd5b8101908080359060200190929190803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506107e6565b005b61040161096f565b005b61040b610a41565b6040518082815260200191505060405180910390f35b610429610a47565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b610473610a70565b604051808215151515815260200191505060405180910390f35b610495610ac7565b6040518082815260200191505060405180910390f35b6104b3610acd565b6040518082815260200191505060405180910390f35b6104d1610ad3565b604051808215151515815260200191505060405180910390f35b6105376004803603604081101561050157600080fd5b8101908080359060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610afc565b005b610541610c85565b6040518082815260200191505060405180910390f35b61055f610c8b565b6040518082815260200191505060405180910390f35b6105c16004803603604081101561058b57600080fd5b8101908080359060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610c91565b005b6105cb610ef7565b6040518082815260200191505060405180910390f35b6105e9610efd565b6040518082815260200191505060405180910390f35b610607610f03565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b61068b6004803603602081101561065f57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610f29565b005b610695610f48565b6040518082815260200191505060405180910390f35b600f5481565b600d60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b60065481565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b601260009054906101000a900460ff1681565b600c5481565b600e60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b60095481565b60018054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156107de5780601f106107b3576101008083540402835291602001916107de565b820191906000526020600020905b8154815290600101906020018083116107c157829003601f168201915b505050505081565b600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614151561088e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602681526020018061132f6026913960400191505060405180910390fd5b600e60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663c3501ff683836040518363ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401808381526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200192505050600060405180830381600087803b15801561095357600080fd5b505af1158015610967573d6000803e3d6000fd5b505050505050565b610977610a70565b151561098257600080fd5b600073ffffffffffffffffffffffffffffffffffffffff166000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a360008060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550565b60115481565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614905090565b60045481565b600b5481565b6000601260009054906101000a900460ff168015610af75750600c54601154014210155b905090565b600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16141515610ba4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602681526020018061132f6026913960400191505060405180910390fd5b600d60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663c3501ff683836040518363ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401808381526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200192505050600060405180830381600087803b158015610c6957600080fd5b505af1158015610c7d573d6000803e3d6000fd5b505050505050565b60055481565b60075481565b600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16141515610d39576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602681526020018061132f6026913960400191505060405180910390fd5b600d60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16637251cd0283836040518363ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401808381526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200192505050600060405180830381600087803b158015610dfe57600080fd5b505af1158015610e12573d6000803e3d6000fd5b50505050600e60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16637251cd0283836040518363ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401808381526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200192505050600060405180830381600087803b158015610edb57600080fd5b505af1158015610eef573d6000803e3d6000fd5b505050505050565b600a5481565b60085481565b600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b610f31610a70565b1515610f3c57600080fd5b610f4581610f4e565b50565b60105481565b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1614151515610f8a57600080fd5b8073ffffffffffffffffffffffffffffffffffffffff166000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a3806000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b600061105d6110578486611178565b836111fd565b90509392505050565b600080600261107586886112a4565b81151561107e57fe5b04905061271061109761109183876111fd565b856111fd565b8115156110a057fe5b04915050949350505050565b60608060206040519080825280601f01601f1916602001820160405280156110e35781602001600182028038833980820191505090505b50905060005b602081101561116e57838160208110151561110057fe5b1a7f010000000000000000000000000000000000000000000000000000000000000002828281518110151561113157fe5b9060200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535080806001019150506110e9565b5080915050919050565b60008282111515156111f2576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601d8152602001807f4d6174684c69623a207375627472616374696f6e206f766572666c6f7700000081525060200191505060405180910390fd5b818303905092915050565b600080831415611210576000905061129e565b6000828402905082848281151561122357fe5b04141515611299576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4d6174684c69623a206d756c7469706c69636174696f6e206f766572666c6f7781525060200191505060405180910390fd5b809150505b92915050565b6000808284019050838110151515611324576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601a8152602001807f4d6174684c69623a206164646974696f6e206f766572666c6f7700000000000081525060200191505060405180910390fd5b809150509291505056fe4f6e6c792063616c6c61626c652066726f6d2074686520636f6c6c61746572616c20706f6f6ca165627a7a72305820317283b72aa2bd300986621cceba2349768c35ec59958e2c24fd9067aa5b08240029",
  "sourceMap": "1076:8096:1:-;;;1813:6;1782:37;;2051:5;2027:29;;;;;;;;;;;;;;;;;;;;3620:1854;8:9:-1;5:2;;;30:1;27;20:12;5:2;3620:1854:1;;;;;;;;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;3620:1854:1;;;;;;;;;;;;;;;;;;524:10:17;515:6;;:19;;;;;;;;;;;;;;;;;;582:6;;;;;;;;;;;549:40;;578:1;549:40;;;;;;;;;;;;3793:13:1;3807:1;3793:16;;;;;;;;;;;;;3779:11;:30;;;;3831:13;3845:1;3831:16;;;;;;;;;;;;;3819:9;:28;;;;3877:11;;3865:9;;:23;3857:78;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3969:13;3983:1;3969:16;;;;;;;;;;;;;3946:20;:39;;;;4012:13;4026:1;4012:16;;;;;;;;;;;;;3995:14;:33;;;;4051:13;4065:1;4051:16;;;;;;;;;;;;;4038:10;:29;;;;4098:3;4085:10;;:16;4077:61;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;4174:1;4156:14;;:19;;4148:57;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;4243:13;4257:1;4243:16;;;;;;;;;;;;;4216:24;;:43;;;;;;;;;;;;;;;;;;4295:13;4309:1;4295:16;;;;;;;;;;;;;4269:23;;:42;;;;;;;;;;;;;;;;;;4343:72;4376:11;;4389:9;;4400:14;;4343:32;;;;;:72;;;:::i;:::-;4321:19;:94;;;;4457:143;4498:11;;4523:9;;4546:14;;4574:13;4588:1;4574:16;;;;;;;;;;;;;4457:27;;;;;:143;;;:::i;:::-;4425:29;:175;;;;4635:143;4676:11;;4701:9;;4724:14;;4752:13;4766:1;4752:16;;;;;;;;;;;;;4635:27;;;;;:143;;;:::i;:::-;4610:22;:168;;;;4845:34;:13;4859:1;4845:16;;;;;;;;;;;;;:32;;;;;:34;;;:::i;:::-;4829:13;:50;;;;;;;;;;;;:::i;:::-;;4889:26;5000:34;:13;5014:1;5000:16;;;;;;;;;;;;;:32;;;;;:34;;;:::i;:::-;5054:29;5048:36;;;;;;;;4918:176;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;4918:176:1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;4918:176:1;4889:205;;5104:27;5217:34;:13;5231:1;5217:16;;;;;;;;;;;;;:32;;;;;:34;;;:::i;:::-;5271:30;5265:37;;;;;;;;5134:178;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;5134:178:1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;5134:178:1;5104:208;;5353:12;5323:19;;:43;;;;;;;;;;;;;;;;;;5407:13;5376:20;;:45;;;;;;;;;;;;;;;;;;5432:35;5450:13;5464:1;5450:16;;;;;;;;;;;;;5432:17;;;:35;;;:::i;:::-;3620:1854;;;;;1076:8096;;3228:228:5;3367:4;3394:55;3403:30;3412:8;3422:10;3403:8;;;:30;;;:::i;:::-;3435:13;3394:8;;;:55;;;:::i;:::-;3387:62;;3228:228;;;;;:::o;3566:323::-;3731:4;3751:13;3795:1;3767:25;3771:8;3781:10;3767:3;;;:25;;;:::i;:::-;:29;;;;;;;;3751:45;;3877:5;3813:61;3822:33;3831:8;3841:13;3822:8;;;:33;;;:::i;:::-;3857:16;3813:8;;;:61;;;:::i;:::-;:69;;;;;;;;3806:76;;;3566:323;;;;;;:::o;153:274:6:-;225:13;250:23;286:2;276:13;;;;;;;;;;;;;;;;;;;;;;;;;29:1:-1;21:6;17:14;116:4;104:10;96:6;87:34;147:4;139:6;135:17;125:27;;0:156;276:13:6;;;;250:39;;304:9;299:87;319:2;315:1;:6;299:87;;;358:14;373:1;358:17;;;;;;;;;;;;342:10;353:1;342:13;;;;;;;;;;;;;;:33;;;;;;;;;;;323:3;;;;;;;299:87;;;;409:10;395:25;;;153:274;;;:::o;1731:107:17:-;863:9;:7;;;:9;;;:::i;:::-;855:18;;;;;;;;1803:28;1822:8;1803:18;;;:28;;;:::i;:::-;1731:107;:::o;1328:159:5:-;1391:7;1423:1;1418;:6;;1410:48;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1479:1;1475;:5;1468:12;;1328:159;;;;:::o;867:246::-;930:7;958:1;953;:6;949:45;;;982:1;975:8;;;;949:45;1004:9;1020:1;1016;:5;1004:17;;1048:1;1043;1039;:5;;;;;;;;:10;1031:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1105:1;1098:8;;;867:246;;;;;:::o;1493:174::-;1551:7;1570:9;1586:1;1582;:5;1570:17;;1610:1;1605;:6;;1597:45;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1659:1;1652:8;;;1493:174;;;;:::o;979:90:17:-;1019:4;1056:6;;;;;;;;;;;1042:20;;:10;:20;;;1035:27;;979:90;:::o;1982:183::-;2075:1;2055:22;;:8;:22;;;;2047:31;;;;;;;;2122:8;2093:38;;2114:6;;;;;;;;;;;2093:38;;;;;;;;;;;;2150:8;2141:6;;:17;;;;;;;;;;;;;;;;;;1982:183;:::o;1076:8096:1:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;:::o;:::-;;;;;;;;;;:::o;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;:::-;;;;;;;",
  "deployedSourceMap": "1076:8096:1:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1076:8096:1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1930:21;;;:::i;:::-;;;;;;;;;;;;;;;;;;;1825:34;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1323:32;;;:::i;:::-;;;;;;;;;;;;;;;;;;;1178:39;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2027:29;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1782:37;;;:::i;:::-;;;;;;;;;;;;;;;;;;;1865:35;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1667:41;;;:::i;:::-;;;;;;;;;;;;;;;;;;;1145:27;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;1145:27:1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6878:282;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;6878:282:1;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;1423:137:17;;;:::i;:::-;;1990:31:1;;;:::i;:::-;;;;;;;;;;;;;;;;;;;659:77:17;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;979:90;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1267:21:1;;;:::i;:::-;;;;;;;;;;;;;;;;;;;1754:22;;;:::i;:::-;;;;;;;;;;;;;;;;;;;7300:146;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;6371:280;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;6371:280:1;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;1294:23;;;:::i;:::-;;;;;;;;;;;;;;;;;;;1435:26;;;:::i;:::-;;;;;;;;;;;;;;;;;;;5784:361;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;5784:361:1;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;1714:34;;;:::i;:::-;;;;;;;;;;;;;;;;;;;1560:31;;;:::i;:::-;;;;;;;;;;;;;;;;;;;1223:38;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1731:107:17;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1731:107:17;;;;;;;;;;;;;;;;;;;:::i;:::-;;1957:27:1;;;:::i;:::-;;;;;;;;;;;;;;;;;;;1930:21;;;;:::o;1825:34::-;;;;;;;;;;;;;:::o;1323:32::-;;;;:::o;1178:39::-;;;;;;;;;;;;;:::o;2027:29::-;;;;;;;;;;;;;:::o;1782:37::-;;;;:::o;1865:35::-;;;;;;;;;;;;;:::o;1667:41::-;;;;:::o;1145:27::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;6878:282::-;9085:23;;;;;;;;;;;9071:37;;:10;:37;;;9063:88;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7097:20;;;;;;;;;;;7083:47;;;7131:11;7144:8;7083:70;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;7083:70:1;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;7083:70:1;;;;6878:282;;:::o;1423:137:17:-;863:9;:7;:9::i;:::-;855:18;;;;;;;;1521:1;1484:40;;1505:6;;;;;;;;;;;1484:40;;;;;;;;;;;;1551:1;1534:6;;:19;;;;;;;;;;;;;;;;;;1423:137::o;1990:31:1:-;;;;:::o;659:77:17:-;697:7;723:6;;;;;;;;;;;716:13;;659:77;:::o;979:90::-;1019:4;1056:6;;;;;;;;;;;1042:20;;:10;:20;;;1035:27;;979:90;:::o;1267:21:1:-;;;;:::o;1754:22::-;;;;:::o;7300:146::-;7354:4;7377:9;;;;;;;;;;;:62;;;;;7421:16;;7399:19;;:38;7391:3;:47;;7377:62;7370:69;;7300:146;:::o;6371:280::-;9085:23;;;;;;;;;;;9071:37;;:10;:37;;;9063:88;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6589:19;;;;;;;;;;;6575:46;;;6622:11;6635:8;6575:69;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;6575:69:1;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;6575:69:1;;;;6371:280;;:::o;1294:23::-;;;;:::o;1435:26::-;;;;:::o;5784:361::-;9085:23;;;;;;;;;;;9071:37;;:10;:37;;;9063:88;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6001:19;;;;;;;;;;;5987:51;;;6039:9;6050:6;5987:70;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;5987:70:1;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;5987:70:1;;;;6081:20;;;;;;;;;;;6067:52;;;6120:9;6131:6;6067:71;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;6067:71:1;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;6067:71:1;;;;5784:361;;:::o;1714:34::-;;;;:::o;1560:31::-;;;;:::o;1223:38::-;;;;;;;;;;;;;:::o;1731:107:17:-;863:9;:7;:9::i;:::-;855:18;;;;;;;;1803:28;1822:8;1803:18;:28::i;:::-;1731:107;:::o;1957:27:1:-;;;;:::o;1982:183:17:-;2075:1;2055:22;;:8;:22;;;;2047:31;;;;;;;;2122:8;2093:38;;2114:6;;;;;;;;;;;2093:38;;;;;;;;;;;;2150:8;2141:6;;:17;;;;;;;;;;;;;;;;;;1982:183;:::o;3228:228:5:-;3367:4;3394:55;3403:30;3412:8;3422:10;3403:8;:30::i;:::-;3435:13;3394:8;:55::i;:::-;3387:62;;3228:228;;;;;:::o;3566:323::-;3731:4;3751:13;3795:1;3767:25;3771:8;3781:10;3767:3;:25::i;:::-;:29;;;;;;;;3751:45;;3877:5;3813:61;3822:33;3831:8;3841:13;3822:8;:33::i;:::-;3857:16;3813:8;:61::i;:::-;:69;;;;;;;;3806:76;;;3566:323;;;;;;:::o;153:274:6:-;225:13;250:23;286:2;276:13;;;;;;;;;;;;;;;;;;;;;;;;;29:1:-1;21:6;17:14;116:4;104:10;96:6;87:34;147:4;139:6;135:17;125:27;;0:156;276:13:6;;;;250:39;;304:9;299:87;319:2;315:1;:6;299:87;;;358:14;373:1;358:17;;;;;;;;;;;;342:10;353:1;342:13;;;;;;;;;;;;;;:33;;;;;;;;;;;323:3;;;;;;;299:87;;;;409:10;395:25;;;153:274;;;:::o;1328:159:5:-;1391:7;1423:1;1418;:6;;1410:48;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1479:1;1475;:5;1468:12;;1328:159;;;;:::o;867:246::-;930:7;958:1;953;:6;949:45;;;982:1;975:8;;;;949:45;1004:9;1020:1;1016;:5;1004:17;;1048:1;1043;1039;:5;;;;;;;;:10;1031:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1105:1;1098:8;;;867:246;;;;;:::o;1493:174::-;1551:7;1570:9;1586:1;1582;:5;1570:17;;1610:1;1605;:6;;1597:45;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1659:1;1652:8;;;1493:174;;;;:::o",
  "source": "/*\n    Copyright 2017-2019 Phillip A. Elsasser\n\n    Licensed under the Apache License, Version 2.0 (the \"License\");\n    you may not use this file except in compliance with the License.\n    You may obtain a copy of the License at\n\n    http://www.apache.org/licenses/LICENSE-2.0\n\n    Unless required by applicable law or agreed to in writing, software\n    distributed under the License is distributed on an \"AS IS\" BASIS,\n    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n    See the License for the specific language governing permissions and\n    limitations under the License.\n*/\n\npragma solidity 0.5.2;\n\nimport \"openzeppelin-solidity/contracts/ownership/Ownable.sol\";\n\nimport \"./libraries/MathLib.sol\";\nimport \"./libraries/StringLib.sol\";\nimport \"./tokens/PositionToken.sol\";\n\n\n/// @title MarketContract base contract implement all needed functionality for trading.\n/// @notice this is the abstract base contract that all contracts should inherit from to\n/// implement different oracle solutions.\n/// @author Phil Elsasser <phil@marketprotocol.io>\ncontract MarketContract is Ownable {\n    using StringLib for *;\n\n    string public CONTRACT_NAME;\n    address public COLLATERAL_TOKEN_ADDRESS;\n    address public COLLATERAL_POOL_ADDRESS;\n    uint public PRICE_CAP;\n    uint public PRICE_FLOOR;\n    uint public PRICE_DECIMAL_PLACES;   // how to convert the pricing from decimal format (if valid) to integer\n    uint public QTY_MULTIPLIER;         // multiplier corresponding to the value of 1 increment in price to token base units\n    uint public COLLATERAL_PER_UNIT;    // required collateral amount for the full range of outcome tokens\n    uint public COLLATERAL_TOKEN_FEE_PER_UNIT;\n    uint public MKT_TOKEN_FEE_PER_UNIT;\n    uint public EXPIRATION;\n    uint public SETTLEMENT_DELAY = 1 days;\n    address public LONG_POSITION_TOKEN;\n    address public SHORT_POSITION_TOKEN;\n\n    // state variables\n    uint public lastPrice;\n    uint public settlementPrice;\n    uint public settlementTimeStamp;\n    bool public isSettled = false;\n\n    // events\n    event UpdatedLastPrice(uint256 price);\n    event ContractSettled(uint settlePrice);\n\n    /// @param contractNames bytes32 array of names\n    ///     contractName            name of the market contract\n    ///     longTokenSymbol         symbol for the long token\n    ///     shortTokenSymbol        symbol for the short token\n    /// @param baseAddresses array of 2 addresses needed for our contract including:\n    ///     ownerAddress                    address of the owner of these contracts.\n    ///     collateralTokenAddress          address of the ERC20 token that will be used for collateral and pricing\n    ///     collateralPoolAddress           address of our collateral pool contract\n    /// @param contractSpecs array of unsigned integers including:\n    ///     floorPrice          minimum tradeable price of this contract, contract enters settlement if breached\n    ///     capPrice            maximum tradeable price of this contract, contract enters settlement if breached\n    ///     priceDecimalPlaces  number of decimal places to convert our queried price from a floating point to\n    ///                         an integer\n    ///     qtyMultiplier       multiply traded qty by this value from base units of collateral token.\n    ///     feeInBasisPoints    fee amount in basis points (Collateral token denominated) for minting.\n    ///     mktFeeInBasisPoints fee amount in basis points (MKT denominated) for minting.\n    ///     expirationTimeStamp seconds from epoch that this contract expires and enters settlement\n    constructor(\n        bytes32[3] memory contractNames,\n        address[3] memory baseAddresses,\n        uint[7] memory contractSpecs\n    ) public\n    {\n        PRICE_FLOOR = contractSpecs[0];\n        PRICE_CAP = contractSpecs[1];\n        require(PRICE_CAP > PRICE_FLOOR, \"PRICE_CAP must be greater than PRICE_FLOOR\");\n\n        PRICE_DECIMAL_PLACES = contractSpecs[2];\n        QTY_MULTIPLIER = contractSpecs[3];\n        EXPIRATION = contractSpecs[6];\n        require(EXPIRATION > now, \"EXPIRATION must be in the future\");\n        require(QTY_MULTIPLIER != 0,\"QTY_MULTIPLIER cannot be 0\");\n\n        COLLATERAL_TOKEN_ADDRESS = baseAddresses[1];\n        COLLATERAL_POOL_ADDRESS = baseAddresses[2];\n        COLLATERAL_PER_UNIT = MathLib.calculateTotalCollateral(PRICE_FLOOR, PRICE_CAP, QTY_MULTIPLIER);\n        COLLATERAL_TOKEN_FEE_PER_UNIT = MathLib.calculateFeePerUnit(\n            PRICE_FLOOR,\n            PRICE_CAP,\n            QTY_MULTIPLIER,\n            contractSpecs[4]\n        );\n        MKT_TOKEN_FEE_PER_UNIT = MathLib.calculateFeePerUnit(\n            PRICE_FLOOR,\n            PRICE_CAP,\n            QTY_MULTIPLIER,\n            contractSpecs[5]\n        );\n\n        // create long and short tokens\n        CONTRACT_NAME = contractNames[0].bytes32ToString();\n        PositionToken longPosToken = new PositionToken(\n            \"MARKET Protocol Long Position Token\",\n            contractNames[1].bytes32ToString(),\n            uint8(PositionToken.MarketSide.Long)\n        );\n        PositionToken shortPosToken = new PositionToken(\n            \"MARKET Protocol Short Position Token\",\n            contractNames[2].bytes32ToString(),\n            uint8(PositionToken.MarketSide.Short)\n        );\n\n        LONG_POSITION_TOKEN = address(longPosToken);\n        SHORT_POSITION_TOKEN = address(shortPosToken);\n\n        transferOwnership(baseAddresses[0]);\n    }\n\n    /*\n    // EXTERNAL - onlyCollateralPool METHODS\n    */\n\n    /// @notice called only by our collateral pool to create long and short position tokens\n    /// @param qtyToMint    qty in base units of how many short and long tokens to mint\n    /// @param minter       address of minter to receive tokens\n    function mintPositionTokens(\n        uint256 qtyToMint,\n        address minter\n    ) external onlyCollateralPool\n    {\n        // mint and distribute short and long position tokens to our caller\n        PositionToken(LONG_POSITION_TOKEN).mintAndSendToken(qtyToMint, minter);\n        PositionToken(SHORT_POSITION_TOKEN).mintAndSendToken(qtyToMint, minter);\n    }\n\n    /// @notice called only by our collateral pool to redeem long position tokens\n    /// @param qtyToRedeem  qty in base units of how many tokens to redeem\n    /// @param redeemer     address of person redeeming tokens\n    function redeemLongToken(\n        uint256 qtyToRedeem,\n        address redeemer\n    ) external onlyCollateralPool\n    {\n        // mint and distribute short and long position tokens to our caller\n        PositionToken(LONG_POSITION_TOKEN).redeemToken(qtyToRedeem, redeemer);\n    }\n\n    /// @notice called only by our collateral pool to redeem short position tokens\n    /// @param qtyToRedeem  qty in base units of how many tokens to redeem\n    /// @param redeemer     address of person redeeming tokens\n    function redeemShortToken(\n        uint256 qtyToRedeem,\n        address redeemer\n    ) external onlyCollateralPool\n    {\n        // mint and distribute short and long position tokens to our caller\n        PositionToken(SHORT_POSITION_TOKEN).redeemToken(qtyToRedeem, redeemer);\n    }\n\n    /*\n    // Public METHODS\n    */\n\n    /// @notice checks to see if a contract is settled, and that the settlement delay has passed\n    function isPostSettlementDelay() public view returns (bool) {\n        return isSettled && (now >= (settlementTimeStamp + SETTLEMENT_DELAY));\n    }\n\n    /*\n    // PRIVATE METHODS\n    */\n\n    /// @dev checks our last query price to see if our contract should enter settlement due to it being past our\n    //  expiration date or outside of our tradeable ranges.\n    function checkSettlement() internal {\n        require(!isSettled, \"Contract is already settled\"); // already settled.\n\n        uint newSettlementPrice;\n        if (now > EXPIRATION) {  // note: miners can cheat this by small increments of time (minutes, not hours)\n            isSettled = true;                   // time based expiration has occurred.\n            newSettlementPrice = lastPrice;\n        } else if (lastPrice >= PRICE_CAP) {    // price is greater or equal to our cap, settle to CAP price\n            isSettled = true;\n            newSettlementPrice = PRICE_CAP;\n        } else if (lastPrice <= PRICE_FLOOR) {  // price is lesser or equal to our floor, settle to FLOOR price\n            isSettled = true;\n            newSettlementPrice = PRICE_FLOOR;\n        }\n\n        if (isSettled) {\n            settleContract(newSettlementPrice);\n        }\n    }\n\n    /// @dev records our final settlement price and fires needed events.\n    /// @param finalSettlementPrice final query price at time of settlement\n    function settleContract(uint finalSettlementPrice) internal {\n        settlementTimeStamp = now;\n        settlementPrice = finalSettlementPrice;\n        emit ContractSettled(finalSettlementPrice);\n    }\n\n    /// @notice only able to be called directly by our collateral pool which controls the position tokens\n    /// for this contract!\n    modifier onlyCollateralPool {\n        require(msg.sender == COLLATERAL_POOL_ADDRESS, \"Only callable from the collateral pool\");\n        _;\n    }\n\n}\n",
  "sourcePath": "/home/travis/build/MARKETProtocol/MARKETProtocol/contracts/MarketContract.sol",
  "ast": {
    "absolutePath": "/home/travis/build/MARKETProtocol/MARKETProtocol/contracts/MarketContract.sol",
    "exportedSymbols": {
      "MarketContract": [
        944
      ]
    },
    "id": 945,
    "nodeType": "SourceUnit",
    "nodes": [
      {
        "id": 550,
        "literals": [
          "solidity",
          "0.5",
          ".2"
        ],
        "nodeType": "PragmaDirective",
        "src": "608:22:1"
      },
      {
        "absolutePath": "openzeppelin-solidity/contracts/ownership/Ownable.sol",
        "file": "openzeppelin-solidity/contracts/ownership/Ownable.sol",
        "id": 551,
        "nodeType": "ImportDirective",
        "scope": 945,
        "sourceUnit": 2455,
        "src": "632:63:1",
        "symbolAliases": [],
        "unitAlias": ""
      },
      {
        "absolutePath": "/home/travis/build/MARKETProtocol/MARKETProtocol/contracts/libraries/MathLib.sol",
        "file": "./libraries/MathLib.sol",
        "id": 552,
        "nodeType": "ImportDirective",
        "scope": 945,
        "sourceUnit": 1490,
        "src": "697:33:1",
        "symbolAliases": [],
        "unitAlias": ""
      },
      {
        "absolutePath": "/home/travis/build/MARKETProtocol/MARKETProtocol/contracts/libraries/StringLib.sol",
        "file": "./libraries/StringLib.sol",
        "id": 553,
        "nodeType": "ImportDirective",
        "scope": 945,
        "sourceUnit": 1531,
        "src": "731:35:1",
        "symbolAliases": [],
        "unitAlias": ""
      },
      {
        "absolutePath": "/home/travis/build/MARKETProtocol/MARKETProtocol/contracts/tokens/PositionToken.sol",
        "file": "./tokens/PositionToken.sol",
        "id": 554,
        "nodeType": "ImportDirective",
        "scope": 945,
        "sourceUnit": 2090,
        "src": "767:36:1",
        "symbolAliases": [],
        "unitAlias": ""
      },
      {
        "baseContracts": [
          {
            "arguments": null,
            "baseName": {
              "contractScope": null,
              "id": 555,
              "name": "Ownable",
              "nodeType": "UserDefinedTypeName",
              "referencedDeclaration": 2454,
              "src": "1103:7:1",
              "typeDescriptions": {
                "typeIdentifier": "t_contract$_Ownable_$2454",
                "typeString": "contract Ownable"
              }
            },
            "id": 556,
            "nodeType": "InheritanceSpecifier",
            "src": "1103:7:1"
          }
        ],
        "contractDependencies": [
          2089,
          2454
        ],
        "contractKind": "contract",
        "documentation": "@title MarketContract base contract implement all needed functionality for trading.\n @notice this is the abstract base contract that all contracts should inherit from to\n implement different oracle solutions.\n @author Phil Elsasser <phil@marketprotocol.io>",
        "fullyImplemented": true,
        "id": 944,
        "linearizedBaseContracts": [
          944,
          2454
        ],
        "name": "MarketContract",
        "nodeType": "ContractDefinition",
        "nodes": [
          {
            "id": 558,
            "libraryName": {
              "contractScope": null,
              "id": 557,
              "name": "StringLib",
              "nodeType": "UserDefinedTypeName",
              "referencedDeclaration": 1530,
              "src": "1123:9:1",
              "typeDescriptions": {
                "typeIdentifier": "t_contract$_StringLib_$1530",
                "typeString": "library StringLib"
              }
            },
            "nodeType": "UsingForDirective",
            "src": "1117:22:1",
            "typeName": null
          },
          {
            "constant": false,
            "id": 560,
            "name": "CONTRACT_NAME",
            "nodeType": "VariableDeclaration",
            "scope": 944,
            "src": "1145:27:1",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_string_storage",
              "typeString": "string"
            },
            "typeName": {
              "id": 559,
              "name": "string",
              "nodeType": "ElementaryTypeName",
              "src": "1145:6:1",
              "typeDescriptions": {
                "typeIdentifier": "t_string_storage_ptr",
                "typeString": "string"
              }
            },
            "value": null,
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 562,
            "name": "COLLATERAL_TOKEN_ADDRESS",
            "nodeType": "VariableDeclaration",
            "scope": 944,
            "src": "1178:39:1",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_address",
              "typeString": "address"
            },
            "typeName": {
              "id": 561,
              "name": "address",
              "nodeType": "ElementaryTypeName",
              "src": "1178:7:1",
              "stateMutability": "nonpayable",
              "typeDescriptions": {
                "typeIdentifier": "t_address",
                "typeString": "address"
              }
            },
            "value": null,
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 564,
            "name": "COLLATERAL_POOL_ADDRESS",
            "nodeType": "VariableDeclaration",
            "scope": 944,
            "src": "1223:38:1",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_address",
              "typeString": "address"
            },
            "typeName": {
              "id": 563,
              "name": "address",
              "nodeType": "ElementaryTypeName",
              "src": "1223:7:1",
              "stateMutability": "nonpayable",
              "typeDescriptions": {
                "typeIdentifier": "t_address",
                "typeString": "address"
              }
            },
            "value": null,
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 566,
            "name": "PRICE_CAP",
            "nodeType": "VariableDeclaration",
            "scope": 944,
            "src": "1267:21:1",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_uint256",
              "typeString": "uint256"
            },
            "typeName": {
              "id": 565,
              "name": "uint",
              "nodeType": "ElementaryTypeName",
              "src": "1267:4:1",
              "typeDescriptions": {
                "typeIdentifier": "t_uint256",
                "typeString": "uint256"
              }
            },
            "value": null,
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 568,
            "name": "PRICE_FLOOR",
            "nodeType": "VariableDeclaration",
            "scope": 944,
            "src": "1294:23:1",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_uint256",
              "typeString": "uint256"
            },
            "typeName": {
              "id": 567,
              "name": "uint",
              "nodeType": "ElementaryTypeName",
              "src": "1294:4:1",
              "typeDescriptions": {
                "typeIdentifier": "t_uint256",
                "typeString": "uint256"
              }
            },
            "value": null,
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 570,
            "name": "PRICE_DECIMAL_PLACES",
            "nodeType": "VariableDeclaration",
            "scope": 944,
            "src": "1323:32:1",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_uint256",
              "typeString": "uint256"
            },
            "typeName": {
              "id": 569,
              "name": "uint",
              "nodeType": "ElementaryTypeName",
              "src": "1323:4:1",
              "typeDescriptions": {
                "typeIdentifier": "t_uint256",
                "typeString": "uint256"
              }
            },
            "value": null,
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 572,
            "name": "QTY_MULTIPLIER",
            "nodeType": "VariableDeclaration",
            "scope": 944,
            "src": "1435:26:1",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_uint256",
              "typeString": "uint256"
            },
            "typeName": {
              "id": 571,
              "name": "uint",
              "nodeType": "ElementaryTypeName",
              "src": "1435:4:1",
              "typeDescriptions": {
                "typeIdentifier": "t_uint256",
                "typeString": "uint256"
              }
            },
            "value": null,
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 574,
            "name": "COLLATERAL_PER_UNIT",
            "nodeType": "VariableDeclaration",
            "scope": 944,
            "src": "1560:31:1",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_uint256",
              "typeString": "uint256"
            },
            "typeName": {
              "id": 573,
              "name": "uint",
              "nodeType": "ElementaryTypeName",
              "src": "1560:4:1",
              "typeDescriptions": {
                "typeIdentifier": "t_uint256",
                "typeString": "uint256"
              }
            },
            "value": null,
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 576,
            "name": "COLLATERAL_TOKEN_FEE_PER_UNIT",
            "nodeType": "VariableDeclaration",
            "scope": 944,
            "src": "1667:41:1",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_uint256",
              "typeString": "uint256"
            },
            "typeName": {
              "id": 575,
              "name": "uint",
              "nodeType": "ElementaryTypeName",
              "src": "1667:4:1",
              "typeDescriptions": {
                "typeIdentifier": "t_uint256",
                "typeString": "uint256"
              }
            },
            "value": null,
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 578,
            "name": "MKT_TOKEN_FEE_PER_UNIT",
            "nodeType": "VariableDeclaration",
            "scope": 944,
            "src": "1714:34:1",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_uint256",
              "typeString": "uint256"
            },
            "typeName": {
              "id": 577,
              "name": "uint",
              "nodeType": "ElementaryTypeName",
              "src": "1714:4:1",
              "typeDescriptions": {
                "typeIdentifier": "t_uint256",
                "typeString": "uint256"
              }
            },
            "value": null,
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 580,
            "name": "EXPIRATION",
            "nodeType": "VariableDeclaration",
            "scope": 944,
            "src": "1754:22:1",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_uint256",
              "typeString": "uint256"
            },
            "typeName": {
              "id": 579,
              "name": "uint",
              "nodeType": "ElementaryTypeName",
              "src": "1754:4:1",
              "typeDescriptions": {
                "typeIdentifier": "t_uint256",
                "typeString": "uint256"
              }
            },
            "value": null,
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 583,
            "name": "SETTLEMENT_DELAY",
            "nodeType": "VariableDeclaration",
            "scope": 944,
            "src": "1782:37:1",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_uint256",
              "typeString": "uint256"
            },
            "typeName": {
              "id": 581,
              "name": "uint",
              "nodeType": "ElementaryTypeName",
              "src": "1782:4:1",
              "typeDescriptions": {
                "typeIdentifier": "t_uint256",
                "typeString": "uint256"
              }
            },
            "value": {
              "argumentTypes": null,
              "hexValue": "31",
              "id": 582,
              "isConstant": false,
              "isLValue": false,
              "isPure": true,
              "kind": "number",
              "lValueRequested": false,
              "nodeType": "Literal",
              "src": "1813:6:1",
              "subdenomination": "days",
              "typeDescriptions": {
                "typeIdentifier": "t_rational_86400_by_1",
                "typeString": "int_const 86400"
              },
              "value": "1"
            },
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 585,
            "name": "LONG_POSITION_TOKEN",
            "nodeType": "VariableDeclaration",
            "scope": 944,
            "src": "1825:34:1",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_address",
              "typeString": "address"
            },
            "typeName": {
              "id": 584,
              "name": "address",
              "nodeType": "ElementaryTypeName",
              "src": "1825:7:1",
              "stateMutability": "nonpayable",
              "typeDescriptions": {
                "typeIdentifier": "t_address",
                "typeString": "address"
              }
            },
            "value": null,
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 587,
            "name": "SHORT_POSITION_TOKEN",
            "nodeType": "VariableDeclaration",
            "scope": 944,
            "src": "1865:35:1",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_address",
              "typeString": "address"
            },
            "typeName": {
              "id": 586,
              "name": "address",
              "nodeType": "ElementaryTypeName",
              "src": "1865:7:1",
              "stateMutability": "nonpayable",
              "typeDescriptions": {
                "typeIdentifier": "t_address",
                "typeString": "address"
              }
            },
            "value": null,
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 589,
            "name": "lastPrice",
            "nodeType": "VariableDeclaration",
            "scope": 944,
            "src": "1930:21:1",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_uint256",
              "typeString": "uint256"
            },
            "typeName": {
              "id": 588,
              "name": "uint",
              "nodeType": "ElementaryTypeName",
              "src": "1930:4:1",
              "typeDescriptions": {
                "typeIdentifier": "t_uint256",
                "typeString": "uint256"
              }
            },
            "value": null,
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 591,
            "name": "settlementPrice",
            "nodeType": "VariableDeclaration",
            "scope": 944,
            "src": "1957:27:1",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_uint256",
              "typeString": "uint256"
            },
            "typeName": {
              "id": 590,
              "name": "uint",
              "nodeType": "ElementaryTypeName",
              "src": "1957:4:1",
              "typeDescriptions": {
                "typeIdentifier": "t_uint256",
                "typeString": "uint256"
              }
            },
            "value": null,
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 593,
            "name": "settlementTimeStamp",
            "nodeType": "VariableDeclaration",
            "scope": 944,
            "src": "1990:31:1",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_uint256",
              "typeString": "uint256"
            },
            "typeName": {
              "id": 592,
              "name": "uint",
              "nodeType": "ElementaryTypeName",
              "src": "1990:4:1",
              "typeDescriptions": {
                "typeIdentifier": "t_uint256",
                "typeString": "uint256"
              }
            },
            "value": null,
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 596,
            "name": "isSettled",
            "nodeType": "VariableDeclaration",
            "scope": 944,
            "src": "2027:29:1",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_bool",
              "typeString": "bool"
            },
            "typeName": {
              "id": 594,
              "name": "bool",
              "nodeType": "ElementaryTypeName",
              "src": "2027:4:1",
              "typeDescriptions": {
                "typeIdentifier": "t_bool",
                "typeString": "bool"
              }
            },
            "value": {
              "argumentTypes": null,
              "hexValue": "66616c7365",
              "id": 595,
              "isConstant": false,
              "isLValue": false,
              "isPure": true,
              "kind": "bool",
              "lValueRequested": false,
              "nodeType": "Literal",
              "src": "2051:5:1",
              "subdenomination": null,
              "typeDescriptions": {
                "typeIdentifier": "t_bool",
                "typeString": "bool"
              },
              "value": "false"
            },
            "visibility": "public"
          },
          {
            "anonymous": false,
            "documentation": null,
            "id": 600,
            "name": "UpdatedLastPrice",
            "nodeType": "EventDefinition",
            "parameters": {
              "id": 599,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 598,
                  "indexed": false,
                  "name": "price",
                  "nodeType": "VariableDeclaration",
                  "scope": 600,
                  "src": "2100:13:1",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 597,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "2100:7:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "2099:15:1"
            },
            "src": "2077:38:1"
          },
          {
            "anonymous": false,
            "documentation": null,
            "id": 604,
            "name": "ContractSettled",
            "nodeType": "EventDefinition",
            "parameters": {
              "id": 603,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 602,
                  "indexed": false,
                  "name": "settlePrice",
                  "nodeType": "VariableDeclaration",
                  "scope": 604,
                  "src": "2142:16:1",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 601,
                    "name": "uint",
                    "nodeType": "ElementaryTypeName",
                    "src": "2142:4:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "2141:18:1"
            },
            "src": "2120:40:1"
          },
          {
            "body": {
              "id": 775,
              "nodeType": "Block",
              "src": "3769:1705:1",
              "statements": [
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 623,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 619,
                      "name": "PRICE_FLOOR",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 568,
                      "src": "3779:11:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "baseExpression": {
                        "argumentTypes": null,
                        "id": 620,
                        "name": "contractSpecs",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 616,
                        "src": "3793:13:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_array$_t_uint256_$7_memory_ptr",
                          "typeString": "uint256[7] memory"
                        }
                      },
                      "id": 622,
                      "indexExpression": {
                        "argumentTypes": null,
                        "hexValue": "30",
                        "id": 621,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "number",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "3807:1:1",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_rational_0_by_1",
                          "typeString": "int_const 0"
                        },
                        "value": "0"
                      },
                      "isConstant": false,
                      "isLValue": true,
                      "isPure": false,
                      "lValueRequested": false,
                      "nodeType": "IndexAccess",
                      "src": "3793:16:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "src": "3779:30:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "id": 624,
                  "nodeType": "ExpressionStatement",
                  "src": "3779:30:1"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 629,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 625,
                      "name": "PRICE_CAP",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 566,
                      "src": "3819:9:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "baseExpression": {
                        "argumentTypes": null,
                        "id": 626,
                        "name": "contractSpecs",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 616,
                        "src": "3831:13:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_array$_t_uint256_$7_memory_ptr",
                          "typeString": "uint256[7] memory"
                        }
                      },
                      "id": 628,
                      "indexExpression": {
                        "argumentTypes": null,
                        "hexValue": "31",
                        "id": 627,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "number",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "3845:1:1",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_rational_1_by_1",
                          "typeString": "int_const 1"
                        },
                        "value": "1"
                      },
                      "isConstant": false,
                      "isLValue": true,
                      "isPure": false,
                      "lValueRequested": false,
                      "nodeType": "IndexAccess",
                      "src": "3831:16:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "src": "3819:28:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "id": 630,
                  "nodeType": "ExpressionStatement",
                  "src": "3819:28:1"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "commonType": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        },
                        "id": 634,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "leftExpression": {
                          "argumentTypes": null,
                          "id": 632,
                          "name": "PRICE_CAP",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 566,
                          "src": "3865:9:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        "nodeType": "BinaryOperation",
                        "operator": ">",
                        "rightExpression": {
                          "argumentTypes": null,
                          "id": 633,
                          "name": "PRICE_FLOOR",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 568,
                          "src": "3877:11:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        "src": "3865:23:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "hexValue": "50524943455f434150206d7573742062652067726561746572207468616e2050524943455f464c4f4f52",
                        "id": 635,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "string",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "3890:44:1",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_stringliteral_24570c6e341fa8bfde1895c377a52d66a23b50f136d3a3e77e80ed90bcd15a08",
                          "typeString": "literal_string \"PRICE_CAP must be greater than PRICE_FLOOR\""
                        },
                        "value": "PRICE_CAP must be greater than PRICE_FLOOR"
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        },
                        {
                          "typeIdentifier": "t_stringliteral_24570c6e341fa8bfde1895c377a52d66a23b50f136d3a3e77e80ed90bcd15a08",
                          "typeString": "literal_string \"PRICE_CAP must be greater than PRICE_FLOOR\""
                        }
                      ],
                      "id": 631,
                      "name": "require",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [
                        3189,
                        3190
                      ],
                      "referencedDeclaration": 3190,
                      "src": "3857:7:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
                        "typeString": "function (bool,string memory) pure"
                      }
                    },
                    "id": 636,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "3857:78:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 637,
                  "nodeType": "ExpressionStatement",
                  "src": "3857:78:1"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 642,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 638,
                      "name": "PRICE_DECIMAL_PLACES",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 570,
                      "src": "3946:20:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "baseExpression": {
                        "argumentTypes": null,
                        "id": 639,
                        "name": "contractSpecs",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 616,
                        "src": "3969:13:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_array$_t_uint256_$7_memory_ptr",
                          "typeString": "uint256[7] memory"
                        }
                      },
                      "id": 641,
                      "indexExpression": {
                        "argumentTypes": null,
                        "hexValue": "32",
                        "id": 640,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "number",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "3983:1:1",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_rational_2_by_1",
                          "typeString": "int_const 2"
                        },
                        "value": "2"
                      },
                      "isConstant": false,
                      "isLValue": true,
                      "isPure": false,
                      "lValueRequested": false,
                      "nodeType": "IndexAccess",
                      "src": "3969:16:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "src": "3946:39:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "id": 643,
                  "nodeType": "ExpressionStatement",
                  "src": "3946:39:1"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 648,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 644,
                      "name": "QTY_MULTIPLIER",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 572,
                      "src": "3995:14:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "baseExpression": {
                        "argumentTypes": null,
                        "id": 645,
                        "name": "contractSpecs",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 616,
                        "src": "4012:13:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_array$_t_uint256_$7_memory_ptr",
                          "typeString": "uint256[7] memory"
                        }
                      },
                      "id": 647,
                      "indexExpression": {
                        "argumentTypes": null,
                        "hexValue": "33",
                        "id": 646,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "number",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "4026:1:1",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_rational_3_by_1",
                          "typeString": "int_const 3"
                        },
                        "value": "3"
                      },
                      "isConstant": false,
                      "isLValue": true,
                      "isPure": false,
                      "lValueRequested": false,
                      "nodeType": "IndexAccess",
                      "src": "4012:16:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "src": "3995:33:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "id": 649,
                  "nodeType": "ExpressionStatement",
                  "src": "3995:33:1"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 654,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 650,
                      "name": "EXPIRATION",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 580,
                      "src": "4038:10:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "baseExpression": {
                        "argumentTypes": null,
                        "id": 651,
                        "name": "contractSpecs",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 616,
                        "src": "4051:13:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_array$_t_uint256_$7_memory_ptr",
                          "typeString": "uint256[7] memory"
                        }
                      },
                      "id": 653,
                      "indexExpression": {
                        "argumentTypes": null,
                        "hexValue": "36",
                        "id": 652,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "number",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "4065:1:1",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_rational_6_by_1",
                          "typeString": "int_const 6"
                        },
                        "value": "6"
                      },
                      "isConstant": false,
                      "isLValue": true,
                      "isPure": false,
                      "lValueRequested": false,
                      "nodeType": "IndexAccess",
                      "src": "4051:16:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "src": "4038:29:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "id": 655,
                  "nodeType": "ExpressionStatement",
                  "src": "4038:29:1"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "commonType": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        },
                        "id": 659,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "leftExpression": {
                          "argumentTypes": null,
                          "id": 657,
                          "name": "EXPIRATION",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 580,
                          "src": "4085:10:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        "nodeType": "BinaryOperation",
                        "operator": ">",
                        "rightExpression": {
                          "argumentTypes": null,
                          "id": 658,
                          "name": "now",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 3188,
                          "src": "4098:3:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        "src": "4085:16:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "hexValue": "45585049524154494f4e206d75737420626520696e2074686520667574757265",
                        "id": 660,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "string",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "4103:34:1",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_stringliteral_e8a0c6b62b433ce5e69c4b827408fddb2e8bfd75dae28294b58df77dac554510",
                          "typeString": "literal_string \"EXPIRATION must be in the future\""
                        },
                        "value": "EXPIRATION must be in the future"
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        },
                        {
                          "typeIdentifier": "t_stringliteral_e8a0c6b62b433ce5e69c4b827408fddb2e8bfd75dae28294b58df77dac554510",
                          "typeString": "literal_string \"EXPIRATION must be in the future\""
                        }
                      ],
                      "id": 656,
                      "name": "require",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [
                        3189,
                        3190
                      ],
                      "referencedDeclaration": 3190,
                      "src": "4077:7:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
                        "typeString": "function (bool,string memory) pure"
                      }
                    },
                    "id": 661,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "4077:61:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 662,
                  "nodeType": "ExpressionStatement",
                  "src": "4077:61:1"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "commonType": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        },
                        "id": 666,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "leftExpression": {
                          "argumentTypes": null,
                          "id": 664,
                          "name": "QTY_MULTIPLIER",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 572,
                          "src": "4156:14:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        "nodeType": "BinaryOperation",
                        "operator": "!=",
                        "rightExpression": {
                          "argumentTypes": null,
                          "hexValue": "30",
                          "id": 665,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": true,
                          "kind": "number",
                          "lValueRequested": false,
                          "nodeType": "Literal",
                          "src": "4174:1:1",
                          "subdenomination": null,
                          "typeDescriptions": {
                            "typeIdentifier": "t_rational_0_by_1",
                            "typeString": "int_const 0"
                          },
                          "value": "0"
                        },
                        "src": "4156:19:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "hexValue": "5154595f4d554c5449504c4945522063616e6e6f742062652030",
                        "id": 667,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "string",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "4176:28:1",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_stringliteral_748a5f570a3627d046bc2e571f821132aa05c98a3bc996fafedf936dd11ac6b6",
                          "typeString": "literal_string \"QTY_MULTIPLIER cannot be 0\""
                        },
                        "value": "QTY_MULTIPLIER cannot be 0"
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        },
                        {
                          "typeIdentifier": "t_stringliteral_748a5f570a3627d046bc2e571f821132aa05c98a3bc996fafedf936dd11ac6b6",
                          "typeString": "literal_string \"QTY_MULTIPLIER cannot be 0\""
                        }
                      ],
                      "id": 663,
                      "name": "require",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [
                        3189,
                        3190
                      ],
                      "referencedDeclaration": 3190,
                      "src": "4148:7:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
                        "typeString": "function (bool,string memory) pure"
                      }
                    },
                    "id": 668,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "4148:57:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 669,
                  "nodeType": "ExpressionStatement",
                  "src": "4148:57:1"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 674,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 670,
                      "name": "COLLATERAL_TOKEN_ADDRESS",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 562,
                      "src": "4216:24:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_address",
                        "typeString": "address"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "baseExpression": {
                        "argumentTypes": null,
                        "id": 671,
                        "name": "baseAddresses",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 612,
                        "src": "4243:13:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_array$_t_address_$3_memory_ptr",
                          "typeString": "address[3] memory"
                        }
                      },
                      "id": 673,
                      "indexExpression": {
                        "argumentTypes": null,
                        "hexValue": "31",
                        "id": 672,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "number",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "4257:1:1",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_rational_1_by_1",
                          "typeString": "int_const 1"
                        },
                        "value": "1"
                      },
                      "isConstant": false,
                      "isLValue": true,
                      "isPure": false,
                      "lValueRequested": false,
                      "nodeType": "IndexAccess",
                      "src": "4243:16:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_address",
                        "typeString": "address"
                      }
                    },
                    "src": "4216:43:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "id": 675,
                  "nodeType": "ExpressionStatement",
                  "src": "4216:43:1"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 680,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 676,
                      "name": "COLLATERAL_POOL_ADDRESS",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 564,
                      "src": "4269:23:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_address",
                        "typeString": "address"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "baseExpression": {
                        "argumentTypes": null,
                        "id": 677,
                        "name": "baseAddresses",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 612,
                        "src": "4295:13:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_array$_t_address_$3_memory_ptr",
                          "typeString": "address[3] memory"
                        }
                      },
                      "id": 679,
                      "indexExpression": {
                        "argumentTypes": null,
                        "hexValue": "32",
                        "id": 678,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "number",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "4309:1:1",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_rational_2_by_1",
                          "typeString": "int_const 2"
                        },
                        "value": "2"
                      },
                      "isConstant": false,
                      "isLValue": true,
                      "isPure": false,
                      "lValueRequested": false,
                      "nodeType": "IndexAccess",
                      "src": "4295:16:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_address",
                        "typeString": "address"
                      }
                    },
                    "src": "4269:42:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "id": 681,
                  "nodeType": "ExpressionStatement",
                  "src": "4269:42:1"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 689,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 682,
                      "name": "COLLATERAL_PER_UNIT",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 574,
                      "src": "4321:19:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "arguments": [
                        {
                          "argumentTypes": null,
                          "id": 685,
                          "name": "PRICE_FLOOR",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 568,
                          "src": "4376:11:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        {
                          "argumentTypes": null,
                          "id": 686,
                          "name": "PRICE_CAP",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 566,
                          "src": "4389:9:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        {
                          "argumentTypes": null,
                          "id": 687,
                          "name": "QTY_MULTIPLIER",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 572,
                          "src": "4400:14:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        }
                      ],
                      "expression": {
                        "argumentTypes": [
                          {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          },
                          {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          },
                          {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        ],
                        "expression": {
                          "argumentTypes": null,
                          "id": 683,
                          "name": "MathLib",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 1489,
                          "src": "4343:7:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_type$_t_contract$_MathLib_$1489_$",
                            "typeString": "type(library MathLib)"
                          }
                        },
                        "id": 684,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "memberName": "calculateTotalCollateral",
                        "nodeType": "MemberAccess",
                        "referencedDeclaration": 1455,
                        "src": "4343:32:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$_t_uint256_$returns$_t_uint256_$",
                          "typeString": "function (uint256,uint256,uint256) pure returns (uint256)"
                        }
                      },
                      "id": 688,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "functionCall",
                      "lValueRequested": false,
                      "names": [],
                      "nodeType": "FunctionCall",
                      "src": "4343:72:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "src": "4321:94:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "id": 690,
                  "nodeType": "ExpressionStatement",
                  "src": "4321:94:1"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 701,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 691,
                      "name": "COLLATERAL_TOKEN_FEE_PER_UNIT",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 576,
                      "src": "4425:29:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "arguments": [
                        {
                          "argumentTypes": null,
                          "id": 694,
                          "name": "PRICE_FLOOR",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 568,
                          "src": "4498:11:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        {
                          "argumentTypes": null,
                          "id": 695,
                          "name": "PRICE_CAP",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 566,
                          "src": "4523:9:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        {
                          "argumentTypes": null,
                          "id": 696,
                          "name": "QTY_MULTIPLIER",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 572,
                          "src": "4546:14:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        {
                          "argumentTypes": null,
                          "baseExpression": {
                            "argumentTypes": null,
                            "id": 697,
                            "name": "contractSpecs",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 616,
                            "src": "4574:13:1",
                            "typeDescriptions": {
                              "typeIdentifier": "t_array$_t_uint256_$7_memory_ptr",
                              "typeString": "uint256[7] memory"
                            }
                          },
                          "id": 699,
                          "indexExpression": {
                            "argumentTypes": null,
                            "hexValue": "34",
                            "id": 698,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": true,
                            "kind": "number",
                            "lValueRequested": false,
                            "nodeType": "Literal",
                            "src": "4588:1:1",
                            "subdenomination": null,
                            "typeDescriptions": {
                              "typeIdentifier": "t_rational_4_by_1",
                              "typeString": "int_const 4"
                            },
                            "value": "4"
                          },
                          "isConstant": false,
                          "isLValue": true,
                          "isPure": false,
                          "lValueRequested": false,
                          "nodeType": "IndexAccess",
                          "src": "4574:16:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        }
                      ],
                      "expression": {
                        "argumentTypes": [
                          {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          },
                          {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          },
                          {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          },
                          {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        ],
                        "expression": {
                          "argumentTypes": null,
                          "id": 692,
                          "name": "MathLib",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 1489,
                          "src": "4457:7:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_type$_t_contract$_MathLib_$1489_$",
                            "typeString": "type(library MathLib)"
                          }
                        },
                        "id": 693,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "memberName": "calculateFeePerUnit",
                        "nodeType": "MemberAccess",
                        "referencedDeclaration": 1488,
                        "src": "4457:27:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$returns$_t_uint256_$",
                          "typeString": "function (uint256,uint256,uint256,uint256) pure returns (uint256)"
                        }
                      },
                      "id": 700,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "functionCall",
                      "lValueRequested": false,
                      "names": [],
                      "nodeType": "FunctionCall",
                      "src": "4457:143:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "src": "4425:175:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "id": 702,
                  "nodeType": "ExpressionStatement",
                  "src": "4425:175:1"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 713,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 703,
                      "name": "MKT_TOKEN_FEE_PER_UNIT",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 578,
                      "src": "4610:22:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "arguments": [
                        {
                          "argumentTypes": null,
                          "id": 706,
                          "name": "PRICE_FLOOR",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 568,
                          "src": "4676:11:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        {
                          "argumentTypes": null,
                          "id": 707,
                          "name": "PRICE_CAP",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 566,
                          "src": "4701:9:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        {
                          "argumentTypes": null,
                          "id": 708,
                          "name": "QTY_MULTIPLIER",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 572,
                          "src": "4724:14:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        {
                          "argumentTypes": null,
                          "baseExpression": {
                            "argumentTypes": null,
                            "id": 709,
                            "name": "contractSpecs",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 616,
                            "src": "4752:13:1",
                            "typeDescriptions": {
                              "typeIdentifier": "t_array$_t_uint256_$7_memory_ptr",
                              "typeString": "uint256[7] memory"
                            }
                          },
                          "id": 711,
                          "indexExpression": {
                            "argumentTypes": null,
                            "hexValue": "35",
                            "id": 710,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": true,
                            "kind": "number",
                            "lValueRequested": false,
                            "nodeType": "Literal",
                            "src": "4766:1:1",
                            "subdenomination": null,
                            "typeDescriptions": {
                              "typeIdentifier": "t_rational_5_by_1",
                              "typeString": "int_const 5"
                            },
                            "value": "5"
                          },
                          "isConstant": false,
                          "isLValue": true,
                          "isPure": false,
                          "lValueRequested": false,
                          "nodeType": "IndexAccess",
                          "src": "4752:16:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        }
                      ],
                      "expression": {
                        "argumentTypes": [
                          {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          },
                          {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          },
                          {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          },
                          {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        ],
                        "expression": {
                          "argumentTypes": null,
                          "id": 704,
                          "name": "MathLib",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 1489,
                          "src": "4635:7:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_type$_t_contract$_MathLib_$1489_$",
                            "typeString": "type(library MathLib)"
                          }
                        },
                        "id": 705,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "memberName": "calculateFeePerUnit",
                        "nodeType": "MemberAccess",
                        "referencedDeclaration": 1488,
                        "src": "4635:27:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$returns$_t_uint256_$",
                          "typeString": "function (uint256,uint256,uint256,uint256) pure returns (uint256)"
                        }
                      },
                      "id": 712,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "functionCall",
                      "lValueRequested": false,
                      "names": [],
                      "nodeType": "FunctionCall",
                      "src": "4635:143:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "src": "4610:168:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "id": 714,
                  "nodeType": "ExpressionStatement",
                  "src": "4610:168:1"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 721,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 715,
                      "name": "CONTRACT_NAME",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 560,
                      "src": "4829:13:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_string_storage",
                        "typeString": "string storage ref"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "arguments": [],
                      "expression": {
                        "argumentTypes": [],
                        "expression": {
                          "argumentTypes": null,
                          "baseExpression": {
                            "argumentTypes": null,
                            "id": 716,
                            "name": "contractNames",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 608,
                            "src": "4845:13:1",
                            "typeDescriptions": {
                              "typeIdentifier": "t_array$_t_bytes32_$3_memory_ptr",
                              "typeString": "bytes32[3] memory"
                            }
                          },
                          "id": 718,
                          "indexExpression": {
                            "argumentTypes": null,
                            "hexValue": "30",
                            "id": 717,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": true,
                            "kind": "number",
                            "lValueRequested": false,
                            "nodeType": "Literal",
                            "src": "4859:1:1",
                            "subdenomination": null,
                            "typeDescriptions": {
                              "typeIdentifier": "t_rational_0_by_1",
                              "typeString": "int_const 0"
                            },
                            "value": "0"
                          },
                          "isConstant": false,
                          "isLValue": true,
                          "isPure": false,
                          "lValueRequested": false,
                          "nodeType": "IndexAccess",
                          "src": "4845:16:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_bytes32",
                            "typeString": "bytes32"
                          }
                        },
                        "id": 719,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "memberName": "bytes32ToString",
                        "nodeType": "MemberAccess",
                        "referencedDeclaration": 1529,
                        "src": "4845:32:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_function_internal_pure$_t_bytes32_$returns$_t_string_memory_ptr_$bound_to$_t_bytes32_$",
                          "typeString": "function (bytes32) pure returns (string memory)"
                        }
                      },
                      "id": 720,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "functionCall",
                      "lValueRequested": false,
                      "names": [],
                      "nodeType": "FunctionCall",
                      "src": "4845:34:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_string_memory_ptr",
                        "typeString": "string memory"
                      }
                    },
                    "src": "4829:50:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_string_storage",
                      "typeString": "string storage ref"
                    }
                  },
                  "id": 722,
                  "nodeType": "ExpressionStatement",
                  "src": "4829:50:1"
                },
                {
                  "assignments": [
                    724
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 724,
                      "name": "longPosToken",
                      "nodeType": "VariableDeclaration",
                      "scope": 775,
                      "src": "4889:26:1",
                      "stateVariable": false,
                      "storageLocation": "default",
                      "typeDescriptions": {
                        "typeIdentifier": "t_contract$_PositionToken_$2089",
                        "typeString": "contract PositionToken"
                      },
                      "typeName": {
                        "contractScope": null,
                        "id": 723,
                        "name": "PositionToken",
                        "nodeType": "UserDefinedTypeName",
                        "referencedDeclaration": 2089,
                        "src": "4889:13:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_contract$_PositionToken_$2089",
                          "typeString": "contract PositionToken"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 739,
                  "initialValue": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "hexValue": "4d41524b45542050726f746f636f6c204c6f6e6720506f736974696f6e20546f6b656e",
                        "id": 727,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "string",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "4949:37:1",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_stringliteral_dea80294dde7ccae15ed6914c7548c05f4e92f0b4f59b8de25e124060ecbb903",
                          "typeString": "literal_string \"MARKET Protocol Long Position Token\""
                        },
                        "value": "MARKET Protocol Long Position Token"
                      },
                      {
                        "argumentTypes": null,
                        "arguments": [],
                        "expression": {
                          "argumentTypes": [],
                          "expression": {
                            "argumentTypes": null,
                            "baseExpression": {
                              "argumentTypes": null,
                              "id": 728,
                              "name": "contractNames",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 608,
                              "src": "5000:13:1",
                              "typeDescriptions": {
                                "typeIdentifier": "t_array$_t_bytes32_$3_memory_ptr",
                                "typeString": "bytes32[3] memory"
                              }
                            },
                            "id": 730,
                            "indexExpression": {
                              "argumentTypes": null,
                              "hexValue": "31",
                              "id": 729,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": true,
                              "kind": "number",
                              "lValueRequested": false,
                              "nodeType": "Literal",
                              "src": "5014:1:1",
                              "subdenomination": null,
                              "typeDescriptions": {
                                "typeIdentifier": "t_rational_1_by_1",
                                "typeString": "int_const 1"
                              },
                              "value": "1"
                            },
                            "isConstant": false,
                            "isLValue": true,
                            "isPure": false,
                            "lValueRequested": false,
                            "nodeType": "IndexAccess",
                            "src": "5000:16:1",
                            "typeDescriptions": {
                              "typeIdentifier": "t_bytes32",
                              "typeString": "bytes32"
                            }
                          },
                          "id": 731,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "lValueRequested": false,
                          "memberName": "bytes32ToString",
                          "nodeType": "MemberAccess",
                          "referencedDeclaration": 1529,
                          "src": "5000:32:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_function_internal_pure$_t_bytes32_$returns$_t_string_memory_ptr_$bound_to$_t_bytes32_$",
                            "typeString": "function (bytes32) pure returns (string memory)"
                          }
                        },
                        "id": 732,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "kind": "functionCall",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "5000:34:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_string_memory_ptr",
                          "typeString": "string memory"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "arguments": [
                          {
                            "argumentTypes": null,
                            "expression": {
                              "argumentTypes": null,
                              "expression": {
                                "argumentTypes": null,
                                "id": 734,
                                "name": "PositionToken",
                                "nodeType": "Identifier",
                                "overloadedDeclarations": [],
                                "referencedDeclaration": 2089,
                                "src": "5054:13:1",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_type$_t_contract$_PositionToken_$2089_$",
                                  "typeString": "type(contract PositionToken)"
                                }
                              },
                              "id": 735,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "lValueRequested": false,
                              "memberName": "MarketSide",
                              "nodeType": "MemberAccess",
                              "referencedDeclaration": 2030,
                              "src": "5054:24:1",
                              "typeDescriptions": {
                                "typeIdentifier": "t_type$_t_enum$_MarketSide_$2030_$",
                                "typeString": "type(enum PositionToken.MarketSide)"
                              }
                            },
                            "id": 736,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": true,
                            "lValueRequested": false,
                            "memberName": "Long",
                            "nodeType": "MemberAccess",
                            "referencedDeclaration": null,
                            "src": "5054:29:1",
                            "typeDescriptions": {
                              "typeIdentifier": "t_enum$_MarketSide_$2030",
                              "typeString": "enum PositionToken.MarketSide"
                            }
                          }
                        ],
                        "expression": {
                          "argumentTypes": [
                            {
                              "typeIdentifier": "t_enum$_MarketSide_$2030",
                              "typeString": "enum PositionToken.MarketSide"
                            }
                          ],
                          "id": 733,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": true,
                          "lValueRequested": false,
                          "nodeType": "ElementaryTypeNameExpression",
                          "src": "5048:5:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_type$_t_uint8_$",
                            "typeString": "type(uint8)"
                          },
                          "typeName": "uint8"
                        },
                        "id": 737,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "typeConversion",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "5048:36:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint8",
                          "typeString": "uint8"
                        }
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_stringliteral_dea80294dde7ccae15ed6914c7548c05f4e92f0b4f59b8de25e124060ecbb903",
                          "typeString": "literal_string \"MARKET Protocol Long Position Token\""
                        },
                        {
                          "typeIdentifier": "t_string_memory_ptr",
                          "typeString": "string memory"
                        },
                        {
                          "typeIdentifier": "t_uint8",
                          "typeString": "uint8"
                        }
                      ],
                      "id": 726,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "nodeType": "NewExpression",
                      "src": "4918:17:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_creation_nonpayable$_t_string_memory_ptr_$_t_string_memory_ptr_$_t_uint8_$returns$_t_contract$_PositionToken_$2089_$",
                        "typeString": "function (string memory,string memory,uint8) returns (contract PositionToken)"
                      },
                      "typeName": {
                        "contractScope": null,
                        "id": 725,
                        "name": "PositionToken",
                        "nodeType": "UserDefinedTypeName",
                        "referencedDeclaration": 2089,
                        "src": "4922:13:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_contract$_PositionToken_$2089",
                          "typeString": "contract PositionToken"
                        }
                      }
                    },
                    "id": 738,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "4918:176:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_contract$_PositionToken_$2089",
                      "typeString": "contract PositionToken"
                    }
                  },
                  "nodeType": "VariableDeclarationStatement",
                  "src": "4889:205:1"
                },
                {
                  "assignments": [
                    741
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 741,
                      "name": "shortPosToken",
                      "nodeType": "VariableDeclaration",
                      "scope": 775,
                      "src": "5104:27:1",
                      "stateVariable": false,
                      "storageLocation": "default",
                      "typeDescriptions": {
                        "typeIdentifier": "t_contract$_PositionToken_$2089",
                        "typeString": "contract PositionToken"
                      },
                      "typeName": {
                        "contractScope": null,
                        "id": 740,
                        "name": "PositionToken",
                        "nodeType": "UserDefinedTypeName",
                        "referencedDeclaration": 2089,
                        "src": "5104:13:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_contract$_PositionToken_$2089",
                          "typeString": "contract PositionToken"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 756,
                  "initialValue": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "hexValue": "4d41524b45542050726f746f636f6c2053686f727420506f736974696f6e20546f6b656e",
                        "id": 744,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "string",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "5165:38:1",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_stringliteral_009c769d34a2b670483d4ea52ce57207c6951c5b1278318933e41fe97729c64f",
                          "typeString": "literal_string \"MARKET Protocol Short Position Token\""
                        },
                        "value": "MARKET Protocol Short Position Token"
                      },
                      {
                        "argumentTypes": null,
                        "arguments": [],
                        "expression": {
                          "argumentTypes": [],
                          "expression": {
                            "argumentTypes": null,
                            "baseExpression": {
                              "argumentTypes": null,
                              "id": 745,
                              "name": "contractNames",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 608,
                              "src": "5217:13:1",
                              "typeDescriptions": {
                                "typeIdentifier": "t_array$_t_bytes32_$3_memory_ptr",
                                "typeString": "bytes32[3] memory"
                              }
                            },
                            "id": 747,
                            "indexExpression": {
                              "argumentTypes": null,
                              "hexValue": "32",
                              "id": 746,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": true,
                              "kind": "number",
                              "lValueRequested": false,
                              "nodeType": "Literal",
                              "src": "5231:1:1",
                              "subdenomination": null,
                              "typeDescriptions": {
                                "typeIdentifier": "t_rational_2_by_1",
                                "typeString": "int_const 2"
                              },
                              "value": "2"
                            },
                            "isConstant": false,
                            "isLValue": true,
                            "isPure": false,
                            "lValueRequested": false,
                            "nodeType": "IndexAccess",
                            "src": "5217:16:1",
                            "typeDescriptions": {
                              "typeIdentifier": "t_bytes32",
                              "typeString": "bytes32"
                            }
                          },
                          "id": 748,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "lValueRequested": false,
                          "memberName": "bytes32ToString",
                          "nodeType": "MemberAccess",
                          "referencedDeclaration": 1529,
                          "src": "5217:32:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_function_internal_pure$_t_bytes32_$returns$_t_string_memory_ptr_$bound_to$_t_bytes32_$",
                            "typeString": "function (bytes32) pure returns (string memory)"
                          }
                        },
                        "id": 749,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "kind": "functionCall",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "5217:34:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_string_memory_ptr",
                          "typeString": "string memory"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "arguments": [
                          {
                            "argumentTypes": null,
                            "expression": {
                              "argumentTypes": null,
                              "expression": {
                                "argumentTypes": null,
                                "id": 751,
                                "name": "PositionToken",
                                "nodeType": "Identifier",
                                "overloadedDeclarations": [],
                                "referencedDeclaration": 2089,
                                "src": "5271:13:1",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_type$_t_contract$_PositionToken_$2089_$",
                                  "typeString": "type(contract PositionToken)"
                                }
                              },
                              "id": 752,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "lValueRequested": false,
                              "memberName": "MarketSide",
                              "nodeType": "MemberAccess",
                              "referencedDeclaration": 2030,
                              "src": "5271:24:1",
                              "typeDescriptions": {
                                "typeIdentifier": "t_type$_t_enum$_MarketSide_$2030_$",
                                "typeString": "type(enum PositionToken.MarketSide)"
                              }
                            },
                            "id": 753,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": true,
                            "lValueRequested": false,
                            "memberName": "Short",
                            "nodeType": "MemberAccess",
                            "referencedDeclaration": null,
                            "src": "5271:30:1",
                            "typeDescriptions": {
                              "typeIdentifier": "t_enum$_MarketSide_$2030",
                              "typeString": "enum PositionToken.MarketSide"
                            }
                          }
                        ],
                        "expression": {
                          "argumentTypes": [
                            {
                              "typeIdentifier": "t_enum$_MarketSide_$2030",
                              "typeString": "enum PositionToken.MarketSide"
                            }
                          ],
                          "id": 750,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": true,
                          "lValueRequested": false,
                          "nodeType": "ElementaryTypeNameExpression",
                          "src": "5265:5:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_type$_t_uint8_$",
                            "typeString": "type(uint8)"
                          },
                          "typeName": "uint8"
                        },
                        "id": 754,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "typeConversion",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "5265:37:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint8",
                          "typeString": "uint8"
                        }
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_stringliteral_009c769d34a2b670483d4ea52ce57207c6951c5b1278318933e41fe97729c64f",
                          "typeString": "literal_string \"MARKET Protocol Short Position Token\""
                        },
                        {
                          "typeIdentifier": "t_string_memory_ptr",
                          "typeString": "string memory"
                        },
                        {
                          "typeIdentifier": "t_uint8",
                          "typeString": "uint8"
                        }
                      ],
                      "id": 743,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "nodeType": "NewExpression",
                      "src": "5134:17:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_creation_nonpayable$_t_string_memory_ptr_$_t_string_memory_ptr_$_t_uint8_$returns$_t_contract$_PositionToken_$2089_$",
                        "typeString": "function (string memory,string memory,uint8) returns (contract PositionToken)"
                      },
                      "typeName": {
                        "contractScope": null,
                        "id": 742,
                        "name": "PositionToken",
                        "nodeType": "UserDefinedTypeName",
                        "referencedDeclaration": 2089,
                        "src": "5138:13:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_contract$_PositionToken_$2089",
                          "typeString": "contract PositionToken"
                        }
                      }
                    },
                    "id": 755,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "5134:178:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_contract$_PositionToken_$2089",
                      "typeString": "contract PositionToken"
                    }
                  },
                  "nodeType": "VariableDeclarationStatement",
                  "src": "5104:208:1"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 761,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 757,
                      "name": "LONG_POSITION_TOKEN",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 585,
                      "src": "5323:19:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_address",
                        "typeString": "address"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "arguments": [
                        {
                          "argumentTypes": null,
                          "id": 759,
                          "name": "longPosToken",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 724,
                          "src": "5353:12:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_contract$_PositionToken_$2089",
                            "typeString": "contract PositionToken"
                          }
                        }
                      ],
                      "expression": {
                        "argumentTypes": [
                          {
                            "typeIdentifier": "t_contract$_PositionToken_$2089",
                            "typeString": "contract PositionToken"
                          }
                        ],
                        "id": 758,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "lValueRequested": false,
                        "nodeType": "ElementaryTypeNameExpression",
                        "src": "5345:7:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_type$_t_address_$",
                          "typeString": "type(address)"
                        },
                        "typeName": "address"
                      },
                      "id": 760,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "typeConversion",
                      "lValueRequested": false,
                      "names": [],
                      "nodeType": "FunctionCall",
                      "src": "5345:21:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_address",
                        "typeString": "address"
                      }
                    },
                    "src": "5323:43:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "id": 762,
                  "nodeType": "ExpressionStatement",
                  "src": "5323:43:1"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 767,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 763,
                      "name": "SHORT_POSITION_TOKEN",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 587,
                      "src": "5376:20:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_address",
                        "typeString": "address"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "arguments": [
                        {
                          "argumentTypes": null,
                          "id": 765,
                          "name": "shortPosToken",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 741,
                          "src": "5407:13:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_contract$_PositionToken_$2089",
                            "typeString": "contract PositionToken"
                          }
                        }
                      ],
                      "expression": {
                        "argumentTypes": [
                          {
                            "typeIdentifier": "t_contract$_PositionToken_$2089",
                            "typeString": "contract PositionToken"
                          }
                        ],
                        "id": 764,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "lValueRequested": false,
                        "nodeType": "ElementaryTypeNameExpression",
                        "src": "5399:7:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_type$_t_address_$",
                          "typeString": "type(address)"
                        },
                        "typeName": "address"
                      },
                      "id": 766,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "typeConversion",
                      "lValueRequested": false,
                      "names": [],
                      "nodeType": "FunctionCall",
                      "src": "5399:22:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_address",
                        "typeString": "address"
                      }
                    },
                    "src": "5376:45:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "id": 768,
                  "nodeType": "ExpressionStatement",
                  "src": "5376:45:1"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "baseExpression": {
                          "argumentTypes": null,
                          "id": 770,
                          "name": "baseAddresses",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 612,
                          "src": "5450:13:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_array$_t_address_$3_memory_ptr",
                            "typeString": "address[3] memory"
                          }
                        },
                        "id": 772,
                        "indexExpression": {
                          "argumentTypes": null,
                          "hexValue": "30",
                          "id": 771,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": true,
                          "kind": "number",
                          "lValueRequested": false,
                          "nodeType": "Literal",
                          "src": "5464:1:1",
                          "subdenomination": null,
                          "typeDescriptions": {
                            "typeIdentifier": "t_rational_0_by_1",
                            "typeString": "int_const 0"
                          },
                          "value": "0"
                        },
                        "isConstant": false,
                        "isLValue": true,
                        "isPure": false,
                        "lValueRequested": false,
                        "nodeType": "IndexAccess",
                        "src": "5450:16:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        }
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        }
                      ],
                      "id": 769,
                      "name": "transferOwnership",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 2430,
                      "src": "5432:17:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_internal_nonpayable$_t_address_$returns$__$",
                        "typeString": "function (address)"
                      }
                    },
                    "id": 773,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "5432:35:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 774,
                  "nodeType": "ExpressionStatement",
                  "src": "5432:35:1"
                }
              ]
            },
            "documentation": "@param contractNames bytes32 array of names\n     contractName            name of the market contract\n     longTokenSymbol         symbol for the long token\n     shortTokenSymbol        symbol for the short token\n @param baseAddresses array of 2 addresses needed for our contract including:\n     ownerAddress                    address of the owner of these contracts.\n     collateralTokenAddress          address of the ERC20 token that will be used for collateral and pricing\n     collateralPoolAddress           address of our collateral pool contract\n @param contractSpecs array of unsigned integers including:\n     floorPrice          minimum tradeable price of this contract, contract enters settlement if breached\n     capPrice            maximum tradeable price of this contract, contract enters settlement if breached\n     priceDecimalPlaces  number of decimal places to convert our queried price from a floating point to\n                         an integer\n     qtyMultiplier       multiply traded qty by this value from base units of collateral token.\n     feeInBasisPoints    fee amount in basis points (Collateral token denominated) for minting.\n     mktFeeInBasisPoints fee amount in basis points (MKT denominated) for minting.\n     expirationTimeStamp seconds from epoch that this contract expires and enters settlement",
            "id": 776,
            "implemented": true,
            "kind": "constructor",
            "modifiers": [],
            "name": "",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 617,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 608,
                  "name": "contractNames",
                  "nodeType": "VariableDeclaration",
                  "scope": 776,
                  "src": "3641:31:1",
                  "stateVariable": false,
                  "storageLocation": "memory",
                  "typeDescriptions": {
                    "typeIdentifier": "t_array$_t_bytes32_$3_memory_ptr",
                    "typeString": "bytes32[3]"
                  },
                  "typeName": {
                    "baseType": {
                      "id": 605,
                      "name": "bytes32",
                      "nodeType": "ElementaryTypeName",
                      "src": "3641:7:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_bytes32",
                        "typeString": "bytes32"
                      }
                    },
                    "id": 607,
                    "length": {
                      "argumentTypes": null,
                      "hexValue": "33",
                      "id": 606,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "number",
                      "lValueRequested": false,
                      "nodeType": "Literal",
                      "src": "3649:1:1",
                      "subdenomination": null,
                      "typeDescriptions": {
                        "typeIdentifier": null,
                        "typeString": null
                      },
                      "value": "3"
                    },
                    "nodeType": "ArrayTypeName",
                    "src": "3641:10:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_array$_t_bytes32_$3_storage_ptr",
                      "typeString": "bytes32[3]"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 612,
                  "name": "baseAddresses",
                  "nodeType": "VariableDeclaration",
                  "scope": 776,
                  "src": "3682:31:1",
                  "stateVariable": false,
                  "storageLocation": "memory",
                  "typeDescriptions": {
                    "typeIdentifier": "t_array$_t_address_$3_memory_ptr",
                    "typeString": "address[3]"
                  },
                  "typeName": {
                    "baseType": {
                      "id": 609,
                      "name": "address",
                      "nodeType": "ElementaryTypeName",
                      "src": "3682:7:1",
                      "stateMutability": "nonpayable",
                      "typeDescriptions": {
                        "typeIdentifier": "t_address",
                        "typeString": "address"
                      }
                    },
                    "id": 611,
                    "length": {
                      "argumentTypes": null,
                      "hexValue": "33",
                      "id": 610,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "number",
                      "lValueRequested": false,
                      "nodeType": "Literal",
                      "src": "3690:1:1",
                      "subdenomination": null,
                      "typeDescriptions": {
                        "typeIdentifier": null,
                        "typeString": null
                      },
                      "value": "3"
                    },
                    "nodeType": "ArrayTypeName",
                    "src": "3682:10:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_array$_t_address_$3_storage_ptr",
                      "typeString": "address[3]"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 616,
                  "name": "contractSpecs",
                  "nodeType": "VariableDeclaration",
                  "scope": 776,
                  "src": "3723:28:1",
                  "stateVariable": false,
                  "storageLocation": "memory",
                  "typeDescriptions": {
                    "typeIdentifier": "t_array$_t_uint256_$7_memory_ptr",
                    "typeString": "uint256[7]"
                  },
                  "typeName": {
                    "baseType": {
                      "id": 613,
                      "name": "uint",
                      "nodeType": "ElementaryTypeName",
                      "src": "3723:4:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "id": 615,
                    "length": {
                      "argumentTypes": null,
                      "hexValue": "37",
                      "id": 614,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "number",
                      "lValueRequested": false,
                      "nodeType": "Literal",
                      "src": "3728:1:1",
                      "subdenomination": null,
                      "typeDescriptions": {
                        "typeIdentifier": null,
                        "typeString": null
                      },
                      "value": "7"
                    },
                    "nodeType": "ArrayTypeName",
                    "src": "3723:7:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_array$_t_uint256_$7_storage_ptr",
                      "typeString": "uint256[7]"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "3631:126:1"
            },
            "returnParameters": {
              "id": 618,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "3769:0:1"
            },
            "scope": 944,
            "src": "3620:1854:1",
            "stateMutability": "nonpayable",
            "superFunction": null,
            "visibility": "public"
          },
          {
            "body": {
              "id": 801,
              "nodeType": "Block",
              "src": "5901:244:1",
              "statements": [
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "id": 789,
                        "name": "qtyToMint",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 778,
                        "src": "6039:9:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "id": 790,
                        "name": "minter",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 780,
                        "src": "6050:6:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        }
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        },
                        {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        }
                      ],
                      "expression": {
                        "argumentTypes": null,
                        "arguments": [
                          {
                            "argumentTypes": null,
                            "id": 786,
                            "name": "LONG_POSITION_TOKEN",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 585,
                            "src": "6001:19:1",
                            "typeDescriptions": {
                              "typeIdentifier": "t_address",
                              "typeString": "address"
                            }
                          }
                        ],
                        "expression": {
                          "argumentTypes": [
                            {
                              "typeIdentifier": "t_address",
                              "typeString": "address"
                            }
                          ],
                          "id": 785,
                          "name": "PositionToken",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 2089,
                          "src": "5987:13:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_type$_t_contract$_PositionToken_$2089_$",
                            "typeString": "type(contract PositionToken)"
                          }
                        },
                        "id": 787,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "kind": "typeConversion",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "5987:34:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_contract$_PositionToken_$2089",
                          "typeString": "contract PositionToken"
                        }
                      },
                      "id": 788,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "memberName": "mintAndSendToken",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": 2073,
                      "src": "5987:51:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_external_nonpayable$_t_uint256_$_t_address_$returns$__$",
                        "typeString": "function (uint256,address) external"
                      }
                    },
                    "id": 791,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "5987:70:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 792,
                  "nodeType": "ExpressionStatement",
                  "src": "5987:70:1"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "id": 797,
                        "name": "qtyToMint",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 778,
                        "src": "6120:9:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "id": 798,
                        "name": "minter",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 780,
                        "src": "6131:6:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        }
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        },
                        {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        }
                      ],
                      "expression": {
                        "argumentTypes": null,
                        "arguments": [
                          {
                            "argumentTypes": null,
                            "id": 794,
                            "name": "SHORT_POSITION_TOKEN",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 587,
                            "src": "6081:20:1",
                            "typeDescriptions": {
                              "typeIdentifier": "t_address",
                              "typeString": "address"
                            }
                          }
                        ],
                        "expression": {
                          "argumentTypes": [
                            {
                              "typeIdentifier": "t_address",
                              "typeString": "address"
                            }
                          ],
                          "id": 793,
                          "name": "PositionToken",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 2089,
                          "src": "6067:13:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_type$_t_contract$_PositionToken_$2089_$",
                            "typeString": "type(contract PositionToken)"
                          }
                        },
                        "id": 795,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "kind": "typeConversion",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "6067:35:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_contract$_PositionToken_$2089",
                          "typeString": "contract PositionToken"
                        }
                      },
                      "id": 796,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "memberName": "mintAndSendToken",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": 2073,
                      "src": "6067:52:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_external_nonpayable$_t_uint256_$_t_address_$returns$__$",
                        "typeString": "function (uint256,address) external"
                      }
                    },
                    "id": 799,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "6067:71:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 800,
                  "nodeType": "ExpressionStatement",
                  "src": "6067:71:1"
                }
              ]
            },
            "documentation": "@notice called only by our collateral pool to create long and short position tokens\n @param qtyToMint    qty in base units of how many short and long tokens to mint\n @param minter       address of minter to receive tokens",
            "id": 802,
            "implemented": true,
            "kind": "function",
            "modifiers": [
              {
                "arguments": null,
                "id": 783,
                "modifierName": {
                  "argumentTypes": null,
                  "id": 782,
                  "name": "onlyCollateralPool",
                  "nodeType": "Identifier",
                  "overloadedDeclarations": [],
                  "referencedDeclaration": 943,
                  "src": "5878:18:1",
                  "typeDescriptions": {
                    "typeIdentifier": "t_modifier$__$",
                    "typeString": "modifier ()"
                  }
                },
                "nodeType": "ModifierInvocation",
                "src": "5878:18:1"
              }
            ],
            "name": "mintPositionTokens",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 781,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 778,
                  "name": "qtyToMint",
                  "nodeType": "VariableDeclaration",
                  "scope": 802,
                  "src": "5821:17:1",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 777,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "5821:7:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 780,
                  "name": "minter",
                  "nodeType": "VariableDeclaration",
                  "scope": 802,
                  "src": "5848:14:1",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_address",
                    "typeString": "address"
                  },
                  "typeName": {
                    "id": 779,
                    "name": "address",
                    "nodeType": "ElementaryTypeName",
                    "src": "5848:7:1",
                    "stateMutability": "nonpayable",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "5811:57:1"
            },
            "returnParameters": {
              "id": 784,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "5901:0:1"
            },
            "scope": 944,
            "src": "5784:361:1",
            "stateMutability": "nonpayable",
            "superFunction": null,
            "visibility": "external"
          },
          {
            "body": {
              "id": 819,
              "nodeType": "Block",
              "src": "6489:162:1",
              "statements": [
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "id": 815,
                        "name": "qtyToRedeem",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 804,
                        "src": "6622:11:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "id": 816,
                        "name": "redeemer",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 806,
                        "src": "6635:8:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        }
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        },
                        {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        }
                      ],
                      "expression": {
                        "argumentTypes": null,
                        "arguments": [
                          {
                            "argumentTypes": null,
                            "id": 812,
                            "name": "LONG_POSITION_TOKEN",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 585,
                            "src": "6589:19:1",
                            "typeDescriptions": {
                              "typeIdentifier": "t_address",
                              "typeString": "address"
                            }
                          }
                        ],
                        "expression": {
                          "argumentTypes": [
                            {
                              "typeIdentifier": "t_address",
                              "typeString": "address"
                            }
                          ],
                          "id": 811,
                          "name": "PositionToken",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 2089,
                          "src": "6575:13:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_type$_t_contract$_PositionToken_$2089_$",
                            "typeString": "type(contract PositionToken)"
                          }
                        },
                        "id": 813,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "kind": "typeConversion",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "6575:34:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_contract$_PositionToken_$2089",
                          "typeString": "contract PositionToken"
                        }
                      },
                      "id": 814,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "memberName": "redeemToken",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": 2088,
                      "src": "6575:46:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_external_nonpayable$_t_uint256_$_t_address_$returns$__$",
                        "typeString": "function (uint256,address) external"
                      }
                    },
                    "id": 817,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "6575:69:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 818,
                  "nodeType": "ExpressionStatement",
                  "src": "6575:69:1"
                }
              ]
            },
            "documentation": "@notice called only by our collateral pool to redeem long position tokens\n @param qtyToRedeem  qty in base units of how many tokens to redeem\n @param redeemer     address of person redeeming tokens",
            "id": 820,
            "implemented": true,
            "kind": "function",
            "modifiers": [
              {
                "arguments": null,
                "id": 809,
                "modifierName": {
                  "argumentTypes": null,
                  "id": 808,
                  "name": "onlyCollateralPool",
                  "nodeType": "Identifier",
                  "overloadedDeclarations": [],
                  "referencedDeclaration": 943,
                  "src": "6466:18:1",
                  "typeDescriptions": {
                    "typeIdentifier": "t_modifier$__$",
                    "typeString": "modifier ()"
                  }
                },
                "nodeType": "ModifierInvocation",
                "src": "6466:18:1"
              }
            ],
            "name": "redeemLongToken",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 807,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 804,
                  "name": "qtyToRedeem",
                  "nodeType": "VariableDeclaration",
                  "scope": 820,
                  "src": "6405:19:1",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 803,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "6405:7:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 806,
                  "name": "redeemer",
                  "nodeType": "VariableDeclaration",
                  "scope": 820,
                  "src": "6434:16:1",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_address",
                    "typeString": "address"
                  },
                  "typeName": {
                    "id": 805,
                    "name": "address",
                    "nodeType": "ElementaryTypeName",
                    "src": "6434:7:1",
                    "stateMutability": "nonpayable",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "6395:61:1"
            },
            "returnParameters": {
              "id": 810,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "6489:0:1"
            },
            "scope": 944,
            "src": "6371:280:1",
            "stateMutability": "nonpayable",
            "superFunction": null,
            "visibility": "external"
          },
          {
            "body": {
              "id": 837,
              "nodeType": "Block",
              "src": "6997:163:1",
              "statements": [
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "id": 833,
                        "name": "qtyToRedeem",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 822,
                        "src": "7131:11:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "id": 834,
                        "name": "redeemer",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 824,
                        "src": "7144:8:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        }
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        },
                        {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        }
                      ],
                      "expression": {
                        "argumentTypes": null,
                        "arguments": [
                          {
                            "argumentTypes": null,
                            "id": 830,
                            "name": "SHORT_POSITION_TOKEN",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 587,
                            "src": "7097:20:1",
                            "typeDescriptions": {
                              "typeIdentifier": "t_address",
                              "typeString": "address"
                            }
                          }
                        ],
                        "expression": {
                          "argumentTypes": [
                            {
                              "typeIdentifier": "t_address",
                              "typeString": "address"
                            }
                          ],
                          "id": 829,
                          "name": "PositionToken",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 2089,
                          "src": "7083:13:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_type$_t_contract$_PositionToken_$2089_$",
                            "typeString": "type(contract PositionToken)"
                          }
                        },
                        "id": 831,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "kind": "typeConversion",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "7083:35:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_contract$_PositionToken_$2089",
                          "typeString": "contract PositionToken"
                        }
                      },
                      "id": 832,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "memberName": "redeemToken",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": 2088,
                      "src": "7083:47:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_external_nonpayable$_t_uint256_$_t_address_$returns$__$",
                        "typeString": "function (uint256,address) external"
                      }
                    },
                    "id": 835,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "7083:70:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 836,
                  "nodeType": "ExpressionStatement",
                  "src": "7083:70:1"
                }
              ]
            },
            "documentation": "@notice called only by our collateral pool to redeem short position tokens\n @param qtyToRedeem  qty in base units of how many tokens to redeem\n @param redeemer     address of person redeeming tokens",
            "id": 838,
            "implemented": true,
            "kind": "function",
            "modifiers": [
              {
                "arguments": null,
                "id": 827,
                "modifierName": {
                  "argumentTypes": null,
                  "id": 826,
                  "name": "onlyCollateralPool",
                  "nodeType": "Identifier",
                  "overloadedDeclarations": [],
                  "referencedDeclaration": 943,
                  "src": "6974:18:1",
                  "typeDescriptions": {
                    "typeIdentifier": "t_modifier$__$",
                    "typeString": "modifier ()"
                  }
                },
                "nodeType": "ModifierInvocation",
                "src": "6974:18:1"
              }
            ],
            "name": "redeemShortToken",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 825,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 822,
                  "name": "qtyToRedeem",
                  "nodeType": "VariableDeclaration",
                  "scope": 838,
                  "src": "6913:19:1",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 821,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "6913:7:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 824,
                  "name": "redeemer",
                  "nodeType": "VariableDeclaration",
                  "scope": 838,
                  "src": "6942:16:1",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_address",
                    "typeString": "address"
                  },
                  "typeName": {
                    "id": 823,
                    "name": "address",
                    "nodeType": "ElementaryTypeName",
                    "src": "6942:7:1",
                    "stateMutability": "nonpayable",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "6903:61:1"
            },
            "returnParameters": {
              "id": 828,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "6997:0:1"
            },
            "scope": 944,
            "src": "6878:282:1",
            "stateMutability": "nonpayable",
            "superFunction": null,
            "visibility": "external"
          },
          {
            "body": {
              "id": 853,
              "nodeType": "Block",
              "src": "7360:86:1",
              "statements": [
                {
                  "expression": {
                    "argumentTypes": null,
                    "commonType": {
                      "typeIdentifier": "t_bool",
                      "typeString": "bool"
                    },
                    "id": 851,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftExpression": {
                      "argumentTypes": null,
                      "id": 843,
                      "name": "isSettled",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 596,
                      "src": "7377:9:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_bool",
                        "typeString": "bool"
                      }
                    },
                    "nodeType": "BinaryOperation",
                    "operator": "&&",
                    "rightExpression": {
                      "argumentTypes": null,
                      "components": [
                        {
                          "argumentTypes": null,
                          "commonType": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          },
                          "id": 849,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "lValueRequested": false,
                          "leftExpression": {
                            "argumentTypes": null,
                            "id": 844,
                            "name": "now",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 3188,
                            "src": "7391:3:1",
                            "typeDescriptions": {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          },
                          "nodeType": "BinaryOperation",
                          "operator": ">=",
                          "rightExpression": {
                            "argumentTypes": null,
                            "components": [
                              {
                                "argumentTypes": null,
                                "commonType": {
                                  "typeIdentifier": "t_uint256",
                                  "typeString": "uint256"
                                },
                                "id": 847,
                                "isConstant": false,
                                "isLValue": false,
                                "isPure": false,
                                "lValueRequested": false,
                                "leftExpression": {
                                  "argumentTypes": null,
                                  "id": 845,
                                  "name": "settlementTimeStamp",
                                  "nodeType": "Identifier",
                                  "overloadedDeclarations": [],
                                  "referencedDeclaration": 593,
                                  "src": "7399:19:1",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_uint256",
                                    "typeString": "uint256"
                                  }
                                },
                                "nodeType": "BinaryOperation",
                                "operator": "+",
                                "rightExpression": {
                                  "argumentTypes": null,
                                  "id": 846,
                                  "name": "SETTLEMENT_DELAY",
                                  "nodeType": "Identifier",
                                  "overloadedDeclarations": [],
                                  "referencedDeclaration": 583,
                                  "src": "7421:16:1",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_uint256",
                                    "typeString": "uint256"
                                  }
                                },
                                "src": "7399:38:1",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_uint256",
                                  "typeString": "uint256"
                                }
                              }
                            ],
                            "id": 848,
                            "isConstant": false,
                            "isInlineArray": false,
                            "isLValue": false,
                            "isPure": false,
                            "lValueRequested": false,
                            "nodeType": "TupleExpression",
                            "src": "7398:40:1",
                            "typeDescriptions": {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          },
                          "src": "7391:47:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_bool",
                            "typeString": "bool"
                          }
                        }
                      ],
                      "id": 850,
                      "isConstant": false,
                      "isInlineArray": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "nodeType": "TupleExpression",
                      "src": "7390:49:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_bool",
                        "typeString": "bool"
                      }
                    },
                    "src": "7377:62:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_bool",
                      "typeString": "bool"
                    }
                  },
                  "functionReturnParameters": 842,
                  "id": 852,
                  "nodeType": "Return",
                  "src": "7370:69:1"
                }
              ]
            },
            "documentation": "@notice checks to see if a contract is settled, and that the settlement delay has passed",
            "id": 854,
            "implemented": true,
            "kind": "function",
            "modifiers": [],
            "name": "isPostSettlementDelay",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 839,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "7330:2:1"
            },
            "returnParameters": {
              "id": 842,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 841,
                  "name": "",
                  "nodeType": "VariableDeclaration",
                  "scope": 854,
                  "src": "7354:4:1",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_bool",
                    "typeString": "bool"
                  },
                  "typeName": {
                    "id": 840,
                    "name": "bool",
                    "nodeType": "ElementaryTypeName",
                    "src": "7354:4:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_bool",
                      "typeString": "bool"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "7353:6:1"
            },
            "scope": 944,
            "src": "7300:146:1",
            "stateMutability": "view",
            "superFunction": null,
            "visibility": "public"
          },
          {
            "body": {
              "id": 912,
              "nodeType": "Block",
              "src": "7699:830:1",
              "statements": [
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "id": 859,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "nodeType": "UnaryOperation",
                        "operator": "!",
                        "prefix": true,
                        "src": "7717:10:1",
                        "subExpression": {
                          "argumentTypes": null,
                          "id": 858,
                          "name": "isSettled",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 596,
                          "src": "7718:9:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_bool",
                            "typeString": "bool"
                          }
                        },
                        "typeDescriptions": {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "hexValue": "436f6e747261637420697320616c726561647920736574746c6564",
                        "id": 860,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "string",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "7729:29:1",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_stringliteral_ca173d03a4252dfa571f586cd2c07cbf7461ad4fb4aa3d483d41782466df287b",
                          "typeString": "literal_string \"Contract is already settled\""
                        },
                        "value": "Contract is already settled"
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        },
                        {
                          "typeIdentifier": "t_stringliteral_ca173d03a4252dfa571f586cd2c07cbf7461ad4fb4aa3d483d41782466df287b",
                          "typeString": "literal_string \"Contract is already settled\""
                        }
                      ],
                      "id": 857,
                      "name": "require",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [
                        3189,
                        3190
                      ],
                      "referencedDeclaration": 3190,
                      "src": "7709:7:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
                        "typeString": "function (bool,string memory) pure"
                      }
                    },
                    "id": 861,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "7709:50:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 862,
                  "nodeType": "ExpressionStatement",
                  "src": "7709:50:1"
                },
                {
                  "assignments": [
                    864
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 864,
                      "name": "newSettlementPrice",
                      "nodeType": "VariableDeclaration",
                      "scope": 912,
                      "src": "7790:23:1",
                      "stateVariable": false,
                      "storageLocation": "default",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      },
                      "typeName": {
                        "id": 863,
                        "name": "uint",
                        "nodeType": "ElementaryTypeName",
                        "src": "7790:4:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 865,
                  "initialValue": null,
                  "nodeType": "VariableDeclarationStatement",
                  "src": "7790:23:1"
                },
                {
                  "condition": {
                    "argumentTypes": null,
                    "commonType": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    },
                    "id": 868,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftExpression": {
                      "argumentTypes": null,
                      "id": 866,
                      "name": "now",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 3188,
                      "src": "7827:3:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "BinaryOperation",
                    "operator": ">",
                    "rightExpression": {
                      "argumentTypes": null,
                      "id": 867,
                      "name": "EXPIRATION",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 580,
                      "src": "7833:10:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "src": "7827:16:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_bool",
                      "typeString": "bool"
                    }
                  },
                  "falseBody": {
                    "condition": {
                      "argumentTypes": null,
                      "commonType": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      },
                      "id": 880,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "leftExpression": {
                        "argumentTypes": null,
                        "id": 878,
                        "name": "lastPrice",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 589,
                        "src": "8078:9:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "nodeType": "BinaryOperation",
                      "operator": ">=",
                      "rightExpression": {
                        "argumentTypes": null,
                        "id": 879,
                        "name": "PRICE_CAP",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 566,
                        "src": "8091:9:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "src": "8078:22:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_bool",
                        "typeString": "bool"
                      }
                    },
                    "falseBody": {
                      "condition": {
                        "argumentTypes": null,
                        "commonType": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        },
                        "id": 892,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "leftExpression": {
                          "argumentTypes": null,
                          "id": 890,
                          "name": "lastPrice",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 589,
                          "src": "8261:9:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        "nodeType": "BinaryOperation",
                        "operator": "<=",
                        "rightExpression": {
                          "argumentTypes": null,
                          "id": 891,
                          "name": "PRICE_FLOOR",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 568,
                          "src": "8274:11:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        "src": "8261:24:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        }
                      },
                      "falseBody": null,
                      "id": 902,
                      "nodeType": "IfStatement",
                      "src": "8257:182:1",
                      "trueBody": {
                        "id": 901,
                        "nodeType": "Block",
                        "src": "8287:152:1",
                        "statements": [
                          {
                            "expression": {
                              "argumentTypes": null,
                              "id": 895,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "lValueRequested": false,
                              "leftHandSide": {
                                "argumentTypes": null,
                                "id": 893,
                                "name": "isSettled",
                                "nodeType": "Identifier",
                                "overloadedDeclarations": [],
                                "referencedDeclaration": 596,
                                "src": "8366:9:1",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_bool",
                                  "typeString": "bool"
                                }
                              },
                              "nodeType": "Assignment",
                              "operator": "=",
                              "rightHandSide": {
                                "argumentTypes": null,
                                "hexValue": "74727565",
                                "id": 894,
                                "isConstant": false,
                                "isLValue": false,
                                "isPure": true,
                                "kind": "bool",
                                "lValueRequested": false,
                                "nodeType": "Literal",
                                "src": "8378:4:1",
                                "subdenomination": null,
                                "typeDescriptions": {
                                  "typeIdentifier": "t_bool",
                                  "typeString": "bool"
                                },
                                "value": "true"
                              },
                              "src": "8366:16:1",
                              "typeDescriptions": {
                                "typeIdentifier": "t_bool",
                                "typeString": "bool"
                              }
                            },
                            "id": 896,
                            "nodeType": "ExpressionStatement",
                            "src": "8366:16:1"
                          },
                          {
                            "expression": {
                              "argumentTypes": null,
                              "id": 899,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "lValueRequested": false,
                              "leftHandSide": {
                                "argumentTypes": null,
                                "id": 897,
                                "name": "newSettlementPrice",
                                "nodeType": "Identifier",
                                "overloadedDeclarations": [],
                                "referencedDeclaration": 864,
                                "src": "8396:18:1",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_uint256",
                                  "typeString": "uint256"
                                }
                              },
                              "nodeType": "Assignment",
                              "operator": "=",
                              "rightHandSide": {
                                "argumentTypes": null,
                                "id": 898,
                                "name": "PRICE_FLOOR",
                                "nodeType": "Identifier",
                                "overloadedDeclarations": [],
                                "referencedDeclaration": 568,
                                "src": "8417:11:1",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_uint256",
                                  "typeString": "uint256"
                                }
                              },
                              "src": "8396:32:1",
                              "typeDescriptions": {
                                "typeIdentifier": "t_uint256",
                                "typeString": "uint256"
                              }
                            },
                            "id": 900,
                            "nodeType": "ExpressionStatement",
                            "src": "8396:32:1"
                          }
                        ]
                      }
                    },
                    "id": 903,
                    "nodeType": "IfStatement",
                    "src": "8074:365:1",
                    "trueBody": {
                      "id": 889,
                      "nodeType": "Block",
                      "src": "8102:149:1",
                      "statements": [
                        {
                          "expression": {
                            "argumentTypes": null,
                            "id": 883,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": false,
                            "lValueRequested": false,
                            "leftHandSide": {
                              "argumentTypes": null,
                              "id": 881,
                              "name": "isSettled",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 596,
                              "src": "8180:9:1",
                              "typeDescriptions": {
                                "typeIdentifier": "t_bool",
                                "typeString": "bool"
                              }
                            },
                            "nodeType": "Assignment",
                            "operator": "=",
                            "rightHandSide": {
                              "argumentTypes": null,
                              "hexValue": "74727565",
                              "id": 882,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": true,
                              "kind": "bool",
                              "lValueRequested": false,
                              "nodeType": "Literal",
                              "src": "8192:4:1",
                              "subdenomination": null,
                              "typeDescriptions": {
                                "typeIdentifier": "t_bool",
                                "typeString": "bool"
                              },
                              "value": "true"
                            },
                            "src": "8180:16:1",
                            "typeDescriptions": {
                              "typeIdentifier": "t_bool",
                              "typeString": "bool"
                            }
                          },
                          "id": 884,
                          "nodeType": "ExpressionStatement",
                          "src": "8180:16:1"
                        },
                        {
                          "expression": {
                            "argumentTypes": null,
                            "id": 887,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": false,
                            "lValueRequested": false,
                            "leftHandSide": {
                              "argumentTypes": null,
                              "id": 885,
                              "name": "newSettlementPrice",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 864,
                              "src": "8210:18:1",
                              "typeDescriptions": {
                                "typeIdentifier": "t_uint256",
                                "typeString": "uint256"
                              }
                            },
                            "nodeType": "Assignment",
                            "operator": "=",
                            "rightHandSide": {
                              "argumentTypes": null,
                              "id": 886,
                              "name": "PRICE_CAP",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 566,
                              "src": "8231:9:1",
                              "typeDescriptions": {
                                "typeIdentifier": "t_uint256",
                                "typeString": "uint256"
                              }
                            },
                            "src": "8210:30:1",
                            "typeDescriptions": {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          },
                          "id": 888,
                          "nodeType": "ExpressionStatement",
                          "src": "8210:30:1"
                        }
                      ]
                    }
                  },
                  "id": 904,
                  "nodeType": "IfStatement",
                  "src": "7823:616:1",
                  "trueBody": {
                    "id": 877,
                    "nodeType": "Block",
                    "src": "7845:223:1",
                    "statements": [
                      {
                        "expression": {
                          "argumentTypes": null,
                          "id": 871,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "lValueRequested": false,
                          "leftHandSide": {
                            "argumentTypes": null,
                            "id": 869,
                            "name": "isSettled",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 596,
                            "src": "7940:9:1",
                            "typeDescriptions": {
                              "typeIdentifier": "t_bool",
                              "typeString": "bool"
                            }
                          },
                          "nodeType": "Assignment",
                          "operator": "=",
                          "rightHandSide": {
                            "argumentTypes": null,
                            "hexValue": "74727565",
                            "id": 870,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": true,
                            "kind": "bool",
                            "lValueRequested": false,
                            "nodeType": "Literal",
                            "src": "7952:4:1",
                            "subdenomination": null,
                            "typeDescriptions": {
                              "typeIdentifier": "t_bool",
                              "typeString": "bool"
                            },
                            "value": "true"
                          },
                          "src": "7940:16:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_bool",
                            "typeString": "bool"
                          }
                        },
                        "id": 872,
                        "nodeType": "ExpressionStatement",
                        "src": "7940:16:1"
                      },
                      {
                        "expression": {
                          "argumentTypes": null,
                          "id": 875,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "lValueRequested": false,
                          "leftHandSide": {
                            "argumentTypes": null,
                            "id": 873,
                            "name": "newSettlementPrice",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 864,
                            "src": "8027:18:1",
                            "typeDescriptions": {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          },
                          "nodeType": "Assignment",
                          "operator": "=",
                          "rightHandSide": {
                            "argumentTypes": null,
                            "id": 874,
                            "name": "lastPrice",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 589,
                            "src": "8048:9:1",
                            "typeDescriptions": {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          },
                          "src": "8027:30:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        "id": 876,
                        "nodeType": "ExpressionStatement",
                        "src": "8027:30:1"
                      }
                    ]
                  }
                },
                {
                  "condition": {
                    "argumentTypes": null,
                    "id": 905,
                    "name": "isSettled",
                    "nodeType": "Identifier",
                    "overloadedDeclarations": [],
                    "referencedDeclaration": 596,
                    "src": "8453:9:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_bool",
                      "typeString": "bool"
                    }
                  },
                  "falseBody": null,
                  "id": 911,
                  "nodeType": "IfStatement",
                  "src": "8449:74:1",
                  "trueBody": {
                    "id": 910,
                    "nodeType": "Block",
                    "src": "8464:59:1",
                    "statements": [
                      {
                        "expression": {
                          "argumentTypes": null,
                          "arguments": [
                            {
                              "argumentTypes": null,
                              "id": 907,
                              "name": "newSettlementPrice",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 864,
                              "src": "8493:18:1",
                              "typeDescriptions": {
                                "typeIdentifier": "t_uint256",
                                "typeString": "uint256"
                              }
                            }
                          ],
                          "expression": {
                            "argumentTypes": [
                              {
                                "typeIdentifier": "t_uint256",
                                "typeString": "uint256"
                              }
                            ],
                            "id": 906,
                            "name": "settleContract",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 931,
                            "src": "8478:14:1",
                            "typeDescriptions": {
                              "typeIdentifier": "t_function_internal_nonpayable$_t_uint256_$returns$__$",
                              "typeString": "function (uint256)"
                            }
                          },
                          "id": 908,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "kind": "functionCall",
                          "lValueRequested": false,
                          "names": [],
                          "nodeType": "FunctionCall",
                          "src": "8478:34:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_tuple$__$",
                            "typeString": "tuple()"
                          }
                        },
                        "id": 909,
                        "nodeType": "ExpressionStatement",
                        "src": "8478:34:1"
                      }
                    ]
                  }
                }
              ]
            },
            "documentation": "@dev checks our last query price to see if our contract should enter settlement due to it being past our",
            "id": 913,
            "implemented": true,
            "kind": "function",
            "modifiers": [],
            "name": "checkSettlement",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 855,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "7687:2:1"
            },
            "returnParameters": {
              "id": 856,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "7699:0:1"
            },
            "scope": 944,
            "src": "7663:866:1",
            "stateMutability": "nonpayable",
            "superFunction": null,
            "visibility": "internal"
          },
          {
            "body": {
              "id": 930,
              "nodeType": "Block",
              "src": "8744:142:1",
              "statements": [
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 920,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 918,
                      "name": "settlementTimeStamp",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 593,
                      "src": "8754:19:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "id": 919,
                      "name": "now",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 3188,
                      "src": "8776:3:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "src": "8754:25:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "id": 921,
                  "nodeType": "ExpressionStatement",
                  "src": "8754:25:1"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 924,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 922,
                      "name": "settlementPrice",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 591,
                      "src": "8789:15:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "id": 923,
                      "name": "finalSettlementPrice",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 915,
                      "src": "8807:20:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "src": "8789:38:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "id": 925,
                  "nodeType": "ExpressionStatement",
                  "src": "8789:38:1"
                },
                {
                  "eventCall": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "id": 927,
                        "name": "finalSettlementPrice",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 915,
                        "src": "8858:20:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      ],
                      "id": 926,
                      "name": "ContractSettled",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 604,
                      "src": "8842:15:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_event_nonpayable$_t_uint256_$returns$__$",
                        "typeString": "function (uint256)"
                      }
                    },
                    "id": 928,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "8842:37:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 929,
                  "nodeType": "EmitStatement",
                  "src": "8837:42:1"
                }
              ]
            },
            "documentation": "@dev records our final settlement price and fires needed events.\n @param finalSettlementPrice final query price at time of settlement",
            "id": 931,
            "implemented": true,
            "kind": "function",
            "modifiers": [],
            "name": "settleContract",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 916,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 915,
                  "name": "finalSettlementPrice",
                  "nodeType": "VariableDeclaration",
                  "scope": 931,
                  "src": "8708:25:1",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 914,
                    "name": "uint",
                    "nodeType": "ElementaryTypeName",
                    "src": "8708:4:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "8707:27:1"
            },
            "returnParameters": {
              "id": 917,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "8744:0:1"
            },
            "scope": 944,
            "src": "8684:202:1",
            "stateMutability": "nonpayable",
            "superFunction": null,
            "visibility": "internal"
          },
          {
            "body": {
              "id": 942,
              "nodeType": "Block",
              "src": "9053:116:1",
              "statements": [
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "commonType": {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        },
                        "id": 937,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "leftExpression": {
                          "argumentTypes": null,
                          "expression": {
                            "argumentTypes": null,
                            "id": 934,
                            "name": "msg",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 3186,
                            "src": "9071:3:1",
                            "typeDescriptions": {
                              "typeIdentifier": "t_magic_message",
                              "typeString": "msg"
                            }
                          },
                          "id": 935,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "lValueRequested": false,
                          "memberName": "sender",
                          "nodeType": "MemberAccess",
                          "referencedDeclaration": null,
                          "src": "9071:10:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_address_payable",
                            "typeString": "address payable"
                          }
                        },
                        "nodeType": "BinaryOperation",
                        "operator": "==",
                        "rightExpression": {
                          "argumentTypes": null,
                          "id": 936,
                          "name": "COLLATERAL_POOL_ADDRESS",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 564,
                          "src": "9085:23:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_address",
                            "typeString": "address"
                          }
                        },
                        "src": "9071:37:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "hexValue": "4f6e6c792063616c6c61626c652066726f6d2074686520636f6c6c61746572616c20706f6f6c",
                        "id": 938,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "string",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "9110:40:1",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_stringliteral_01055747720d725252280235b71e0d12366d812b78ea07163258ecbeba48bae5",
                          "typeString": "literal_string \"Only callable from the collateral pool\""
                        },
                        "value": "Only callable from the collateral pool"
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        },
                        {
                          "typeIdentifier": "t_stringliteral_01055747720d725252280235b71e0d12366d812b78ea07163258ecbeba48bae5",
                          "typeString": "literal_string \"Only callable from the collateral pool\""
                        }
                      ],
                      "id": 933,
                      "name": "require",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [
                        3189,
                        3190
                      ],
                      "referencedDeclaration": 3190,
                      "src": "9063:7:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
                        "typeString": "function (bool,string memory) pure"
                      }
                    },
                    "id": 939,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "9063:88:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 940,
                  "nodeType": "ExpressionStatement",
                  "src": "9063:88:1"
                },
                {
                  "id": 941,
                  "nodeType": "PlaceholderStatement",
                  "src": "9161:1:1"
                }
              ]
            },
            "documentation": "@notice only able to be called directly by our collateral pool which controls the position tokens\n for this contract!",
            "id": 943,
            "name": "onlyCollateralPool",
            "nodeType": "ModifierDefinition",
            "parameters": {
              "id": 932,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "9053:0:1"
            },
            "src": "9025:144:1",
            "visibility": "internal"
          }
        ],
        "scope": 945,
        "src": "1076:8096:1"
      }
    ],
    "src": "608:8565:1"
  },
  "legacyAST": {
    "absolutePath": "/home/travis/build/MARKETProtocol/MARKETProtocol/contracts/MarketContract.sol",
    "exportedSymbols": {
      "MarketContract": [
        944
      ]
    },
    "id": 945,
    "nodeType": "SourceUnit",
    "nodes": [
      {
        "id": 550,
        "literals": [
          "solidity",
          "0.5",
          ".2"
        ],
        "nodeType": "PragmaDirective",
        "src": "608:22:1"
      },
      {
        "absolutePath": "openzeppelin-solidity/contracts/ownership/Ownable.sol",
        "file": "openzeppelin-solidity/contracts/ownership/Ownable.sol",
        "id": 551,
        "nodeType": "ImportDirective",
        "scope": 945,
        "sourceUnit": 2455,
        "src": "632:63:1",
        "symbolAliases": [],
        "unitAlias": ""
      },
      {
        "absolutePath": "/home/travis/build/MARKETProtocol/MARKETProtocol/contracts/libraries/MathLib.sol",
        "file": "./libraries/MathLib.sol",
        "id": 552,
        "nodeType": "ImportDirective",
        "scope": 945,
        "sourceUnit": 1490,
        "src": "697:33:1",
        "symbolAliases": [],
        "unitAlias": ""
      },
      {
        "absolutePath": "/home/travis/build/MARKETProtocol/MARKETProtocol/contracts/libraries/StringLib.sol",
        "file": "./libraries/StringLib.sol",
        "id": 553,
        "nodeType": "ImportDirective",
        "scope": 945,
        "sourceUnit": 1531,
        "src": "731:35:1",
        "symbolAliases": [],
        "unitAlias": ""
      },
      {
        "absolutePath": "/home/travis/build/MARKETProtocol/MARKETProtocol/contracts/tokens/PositionToken.sol",
        "file": "./tokens/PositionToken.sol",
        "id": 554,
        "nodeType": "ImportDirective",
        "scope": 945,
        "sourceUnit": 2090,
        "src": "767:36:1",
        "symbolAliases": [],
        "unitAlias": ""
      },
      {
        "baseContracts": [
          {
            "arguments": null,
            "baseName": {
              "contractScope": null,
              "id": 555,
              "name": "Ownable",
              "nodeType": "UserDefinedTypeName",
              "referencedDeclaration": 2454,
              "src": "1103:7:1",
              "typeDescriptions": {
                "typeIdentifier": "t_contract$_Ownable_$2454",
                "typeString": "contract Ownable"
              }
            },
            "id": 556,
            "nodeType": "InheritanceSpecifier",
            "src": "1103:7:1"
          }
        ],
        "contractDependencies": [
          2089,
          2454
        ],
        "contractKind": "contract",
        "documentation": "@title MarketContract base contract implement all needed functionality for trading.\n @notice this is the abstract base contract that all contracts should inherit from to\n implement different oracle solutions.\n @author Phil Elsasser <phil@marketprotocol.io>",
        "fullyImplemented": true,
        "id": 944,
        "linearizedBaseContracts": [
          944,
          2454
        ],
        "name": "MarketContract",
        "nodeType": "ContractDefinition",
        "nodes": [
          {
            "id": 558,
            "libraryName": {
              "contractScope": null,
              "id": 557,
              "name": "StringLib",
              "nodeType": "UserDefinedTypeName",
              "referencedDeclaration": 1530,
              "src": "1123:9:1",
              "typeDescriptions": {
                "typeIdentifier": "t_contract$_StringLib_$1530",
                "typeString": "library StringLib"
              }
            },
            "nodeType": "UsingForDirective",
            "src": "1117:22:1",
            "typeName": null
          },
          {
            "constant": false,
            "id": 560,
            "name": "CONTRACT_NAME",
            "nodeType": "VariableDeclaration",
            "scope": 944,
            "src": "1145:27:1",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_string_storage",
              "typeString": "string"
            },
            "typeName": {
              "id": 559,
              "name": "string",
              "nodeType": "ElementaryTypeName",
              "src": "1145:6:1",
              "typeDescriptions": {
                "typeIdentifier": "t_string_storage_ptr",
                "typeString": "string"
              }
            },
            "value": null,
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 562,
            "name": "COLLATERAL_TOKEN_ADDRESS",
            "nodeType": "VariableDeclaration",
            "scope": 944,
            "src": "1178:39:1",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_address",
              "typeString": "address"
            },
            "typeName": {
              "id": 561,
              "name": "address",
              "nodeType": "ElementaryTypeName",
              "src": "1178:7:1",
              "stateMutability": "nonpayable",
              "typeDescriptions": {
                "typeIdentifier": "t_address",
                "typeString": "address"
              }
            },
            "value": null,
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 564,
            "name": "COLLATERAL_POOL_ADDRESS",
            "nodeType": "VariableDeclaration",
            "scope": 944,
            "src": "1223:38:1",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_address",
              "typeString": "address"
            },
            "typeName": {
              "id": 563,
              "name": "address",
              "nodeType": "ElementaryTypeName",
              "src": "1223:7:1",
              "stateMutability": "nonpayable",
              "typeDescriptions": {
                "typeIdentifier": "t_address",
                "typeString": "address"
              }
            },
            "value": null,
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 566,
            "name": "PRICE_CAP",
            "nodeType": "VariableDeclaration",
            "scope": 944,
            "src": "1267:21:1",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_uint256",
              "typeString": "uint256"
            },
            "typeName": {
              "id": 565,
              "name": "uint",
              "nodeType": "ElementaryTypeName",
              "src": "1267:4:1",
              "typeDescriptions": {
                "typeIdentifier": "t_uint256",
                "typeString": "uint256"
              }
            },
            "value": null,
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 568,
            "name": "PRICE_FLOOR",
            "nodeType": "VariableDeclaration",
            "scope": 944,
            "src": "1294:23:1",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_uint256",
              "typeString": "uint256"
            },
            "typeName": {
              "id": 567,
              "name": "uint",
              "nodeType": "ElementaryTypeName",
              "src": "1294:4:1",
              "typeDescriptions": {
                "typeIdentifier": "t_uint256",
                "typeString": "uint256"
              }
            },
            "value": null,
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 570,
            "name": "PRICE_DECIMAL_PLACES",
            "nodeType": "VariableDeclaration",
            "scope": 944,
            "src": "1323:32:1",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_uint256",
              "typeString": "uint256"
            },
            "typeName": {
              "id": 569,
              "name": "uint",
              "nodeType": "ElementaryTypeName",
              "src": "1323:4:1",
              "typeDescriptions": {
                "typeIdentifier": "t_uint256",
                "typeString": "uint256"
              }
            },
            "value": null,
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 572,
            "name": "QTY_MULTIPLIER",
            "nodeType": "VariableDeclaration",
            "scope": 944,
            "src": "1435:26:1",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_uint256",
              "typeString": "uint256"
            },
            "typeName": {
              "id": 571,
              "name": "uint",
              "nodeType": "ElementaryTypeName",
              "src": "1435:4:1",
              "typeDescriptions": {
                "typeIdentifier": "t_uint256",
                "typeString": "uint256"
              }
            },
            "value": null,
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 574,
            "name": "COLLATERAL_PER_UNIT",
            "nodeType": "VariableDeclaration",
            "scope": 944,
            "src": "1560:31:1",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_uint256",
              "typeString": "uint256"
            },
            "typeName": {
              "id": 573,
              "name": "uint",
              "nodeType": "ElementaryTypeName",
              "src": "1560:4:1",
              "typeDescriptions": {
                "typeIdentifier": "t_uint256",
                "typeString": "uint256"
              }
            },
            "value": null,
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 576,
            "name": "COLLATERAL_TOKEN_FEE_PER_UNIT",
            "nodeType": "VariableDeclaration",
            "scope": 944,
            "src": "1667:41:1",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_uint256",
              "typeString": "uint256"
            },
            "typeName": {
              "id": 575,
              "name": "uint",
              "nodeType": "ElementaryTypeName",
              "src": "1667:4:1",
              "typeDescriptions": {
                "typeIdentifier": "t_uint256",
                "typeString": "uint256"
              }
            },
            "value": null,
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 578,
            "name": "MKT_TOKEN_FEE_PER_UNIT",
            "nodeType": "VariableDeclaration",
            "scope": 944,
            "src": "1714:34:1",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_uint256",
              "typeString": "uint256"
            },
            "typeName": {
              "id": 577,
              "name": "uint",
              "nodeType": "ElementaryTypeName",
              "src": "1714:4:1",
              "typeDescriptions": {
                "typeIdentifier": "t_uint256",
                "typeString": "uint256"
              }
            },
            "value": null,
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 580,
            "name": "EXPIRATION",
            "nodeType": "VariableDeclaration",
            "scope": 944,
            "src": "1754:22:1",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_uint256",
              "typeString": "uint256"
            },
            "typeName": {
              "id": 579,
              "name": "uint",
              "nodeType": "ElementaryTypeName",
              "src": "1754:4:1",
              "typeDescriptions": {
                "typeIdentifier": "t_uint256",
                "typeString": "uint256"
              }
            },
            "value": null,
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 583,
            "name": "SETTLEMENT_DELAY",
            "nodeType": "VariableDeclaration",
            "scope": 944,
            "src": "1782:37:1",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_uint256",
              "typeString": "uint256"
            },
            "typeName": {
              "id": 581,
              "name": "uint",
              "nodeType": "ElementaryTypeName",
              "src": "1782:4:1",
              "typeDescriptions": {
                "typeIdentifier": "t_uint256",
                "typeString": "uint256"
              }
            },
            "value": {
              "argumentTypes": null,
              "hexValue": "31",
              "id": 582,
              "isConstant": false,
              "isLValue": false,
              "isPure": true,
              "kind": "number",
              "lValueRequested": false,
              "nodeType": "Literal",
              "src": "1813:6:1",
              "subdenomination": "days",
              "typeDescriptions": {
                "typeIdentifier": "t_rational_86400_by_1",
                "typeString": "int_const 86400"
              },
              "value": "1"
            },
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 585,
            "name": "LONG_POSITION_TOKEN",
            "nodeType": "VariableDeclaration",
            "scope": 944,
            "src": "1825:34:1",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_address",
              "typeString": "address"
            },
            "typeName": {
              "id": 584,
              "name": "address",
              "nodeType": "ElementaryTypeName",
              "src": "1825:7:1",
              "stateMutability": "nonpayable",
              "typeDescriptions": {
                "typeIdentifier": "t_address",
                "typeString": "address"
              }
            },
            "value": null,
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 587,
            "name": "SHORT_POSITION_TOKEN",
            "nodeType": "VariableDeclaration",
            "scope": 944,
            "src": "1865:35:1",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_address",
              "typeString": "address"
            },
            "typeName": {
              "id": 586,
              "name": "address",
              "nodeType": "ElementaryTypeName",
              "src": "1865:7:1",
              "stateMutability": "nonpayable",
              "typeDescriptions": {
                "typeIdentifier": "t_address",
                "typeString": "address"
              }
            },
            "value": null,
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 589,
            "name": "lastPrice",
            "nodeType": "VariableDeclaration",
            "scope": 944,
            "src": "1930:21:1",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_uint256",
              "typeString": "uint256"
            },
            "typeName": {
              "id": 588,
              "name": "uint",
              "nodeType": "ElementaryTypeName",
              "src": "1930:4:1",
              "typeDescriptions": {
                "typeIdentifier": "t_uint256",
                "typeString": "uint256"
              }
            },
            "value": null,
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 591,
            "name": "settlementPrice",
            "nodeType": "VariableDeclaration",
            "scope": 944,
            "src": "1957:27:1",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_uint256",
              "typeString": "uint256"
            },
            "typeName": {
              "id": 590,
              "name": "uint",
              "nodeType": "ElementaryTypeName",
              "src": "1957:4:1",
              "typeDescriptions": {
                "typeIdentifier": "t_uint256",
                "typeString": "uint256"
              }
            },
            "value": null,
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 593,
            "name": "settlementTimeStamp",
            "nodeType": "VariableDeclaration",
            "scope": 944,
            "src": "1990:31:1",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_uint256",
              "typeString": "uint256"
            },
            "typeName": {
              "id": 592,
              "name": "uint",
              "nodeType": "ElementaryTypeName",
              "src": "1990:4:1",
              "typeDescriptions": {
                "typeIdentifier": "t_uint256",
                "typeString": "uint256"
              }
            },
            "value": null,
            "visibility": "public"
          },
          {
            "constant": false,
            "id": 596,
            "name": "isSettled",
            "nodeType": "VariableDeclaration",
            "scope": 944,
            "src": "2027:29:1",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_bool",
              "typeString": "bool"
            },
            "typeName": {
              "id": 594,
              "name": "bool",
              "nodeType": "ElementaryTypeName",
              "src": "2027:4:1",
              "typeDescriptions": {
                "typeIdentifier": "t_bool",
                "typeString": "bool"
              }
            },
            "value": {
              "argumentTypes": null,
              "hexValue": "66616c7365",
              "id": 595,
              "isConstant": false,
              "isLValue": false,
              "isPure": true,
              "kind": "bool",
              "lValueRequested": false,
              "nodeType": "Literal",
              "src": "2051:5:1",
              "subdenomination": null,
              "typeDescriptions": {
                "typeIdentifier": "t_bool",
                "typeString": "bool"
              },
              "value": "false"
            },
            "visibility": "public"
          },
          {
            "anonymous": false,
            "documentation": null,
            "id": 600,
            "name": "UpdatedLastPrice",
            "nodeType": "EventDefinition",
            "parameters": {
              "id": 599,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 598,
                  "indexed": false,
                  "name": "price",
                  "nodeType": "VariableDeclaration",
                  "scope": 600,
                  "src": "2100:13:1",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 597,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "2100:7:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "2099:15:1"
            },
            "src": "2077:38:1"
          },
          {
            "anonymous": false,
            "documentation": null,
            "id": 604,
            "name": "ContractSettled",
            "nodeType": "EventDefinition",
            "parameters": {
              "id": 603,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 602,
                  "indexed": false,
                  "name": "settlePrice",
                  "nodeType": "VariableDeclaration",
                  "scope": 604,
                  "src": "2142:16:1",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 601,
                    "name": "uint",
                    "nodeType": "ElementaryTypeName",
                    "src": "2142:4:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "2141:18:1"
            },
            "src": "2120:40:1"
          },
          {
            "body": {
              "id": 775,
              "nodeType": "Block",
              "src": "3769:1705:1",
              "statements": [
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 623,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 619,
                      "name": "PRICE_FLOOR",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 568,
                      "src": "3779:11:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "baseExpression": {
                        "argumentTypes": null,
                        "id": 620,
                        "name": "contractSpecs",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 616,
                        "src": "3793:13:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_array$_t_uint256_$7_memory_ptr",
                          "typeString": "uint256[7] memory"
                        }
                      },
                      "id": 622,
                      "indexExpression": {
                        "argumentTypes": null,
                        "hexValue": "30",
                        "id": 621,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "number",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "3807:1:1",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_rational_0_by_1",
                          "typeString": "int_const 0"
                        },
                        "value": "0"
                      },
                      "isConstant": false,
                      "isLValue": true,
                      "isPure": false,
                      "lValueRequested": false,
                      "nodeType": "IndexAccess",
                      "src": "3793:16:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "src": "3779:30:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "id": 624,
                  "nodeType": "ExpressionStatement",
                  "src": "3779:30:1"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 629,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 625,
                      "name": "PRICE_CAP",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 566,
                      "src": "3819:9:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "baseExpression": {
                        "argumentTypes": null,
                        "id": 626,
                        "name": "contractSpecs",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 616,
                        "src": "3831:13:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_array$_t_uint256_$7_memory_ptr",
                          "typeString": "uint256[7] memory"
                        }
                      },
                      "id": 628,
                      "indexExpression": {
                        "argumentTypes": null,
                        "hexValue": "31",
                        "id": 627,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "number",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "3845:1:1",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_rational_1_by_1",
                          "typeString": "int_const 1"
                        },
                        "value": "1"
                      },
                      "isConstant": false,
                      "isLValue": true,
                      "isPure": false,
                      "lValueRequested": false,
                      "nodeType": "IndexAccess",
                      "src": "3831:16:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "src": "3819:28:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "id": 630,
                  "nodeType": "ExpressionStatement",
                  "src": "3819:28:1"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "commonType": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        },
                        "id": 634,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "leftExpression": {
                          "argumentTypes": null,
                          "id": 632,
                          "name": "PRICE_CAP",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 566,
                          "src": "3865:9:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        "nodeType": "BinaryOperation",
                        "operator": ">",
                        "rightExpression": {
                          "argumentTypes": null,
                          "id": 633,
                          "name": "PRICE_FLOOR",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 568,
                          "src": "3877:11:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        "src": "3865:23:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "hexValue": "50524943455f434150206d7573742062652067726561746572207468616e2050524943455f464c4f4f52",
                        "id": 635,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "string",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "3890:44:1",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_stringliteral_24570c6e341fa8bfde1895c377a52d66a23b50f136d3a3e77e80ed90bcd15a08",
                          "typeString": "literal_string \"PRICE_CAP must be greater than PRICE_FLOOR\""
                        },
                        "value": "PRICE_CAP must be greater than PRICE_FLOOR"
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        },
                        {
                          "typeIdentifier": "t_stringliteral_24570c6e341fa8bfde1895c377a52d66a23b50f136d3a3e77e80ed90bcd15a08",
                          "typeString": "literal_string \"PRICE_CAP must be greater than PRICE_FLOOR\""
                        }
                      ],
                      "id": 631,
                      "name": "require",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [
                        3189,
                        3190
                      ],
                      "referencedDeclaration": 3190,
                      "src": "3857:7:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
                        "typeString": "function (bool,string memory) pure"
                      }
                    },
                    "id": 636,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "3857:78:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 637,
                  "nodeType": "ExpressionStatement",
                  "src": "3857:78:1"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 642,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 638,
                      "name": "PRICE_DECIMAL_PLACES",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 570,
                      "src": "3946:20:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "baseExpression": {
                        "argumentTypes": null,
                        "id": 639,
                        "name": "contractSpecs",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 616,
                        "src": "3969:13:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_array$_t_uint256_$7_memory_ptr",
                          "typeString": "uint256[7] memory"
                        }
                      },
                      "id": 641,
                      "indexExpression": {
                        "argumentTypes": null,
                        "hexValue": "32",
                        "id": 640,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "number",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "3983:1:1",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_rational_2_by_1",
                          "typeString": "int_const 2"
                        },
                        "value": "2"
                      },
                      "isConstant": false,
                      "isLValue": true,
                      "isPure": false,
                      "lValueRequested": false,
                      "nodeType": "IndexAccess",
                      "src": "3969:16:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "src": "3946:39:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "id": 643,
                  "nodeType": "ExpressionStatement",
                  "src": "3946:39:1"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 648,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 644,
                      "name": "QTY_MULTIPLIER",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 572,
                      "src": "3995:14:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "baseExpression": {
                        "argumentTypes": null,
                        "id": 645,
                        "name": "contractSpecs",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 616,
                        "src": "4012:13:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_array$_t_uint256_$7_memory_ptr",
                          "typeString": "uint256[7] memory"
                        }
                      },
                      "id": 647,
                      "indexExpression": {
                        "argumentTypes": null,
                        "hexValue": "33",
                        "id": 646,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "number",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "4026:1:1",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_rational_3_by_1",
                          "typeString": "int_const 3"
                        },
                        "value": "3"
                      },
                      "isConstant": false,
                      "isLValue": true,
                      "isPure": false,
                      "lValueRequested": false,
                      "nodeType": "IndexAccess",
                      "src": "4012:16:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "src": "3995:33:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "id": 649,
                  "nodeType": "ExpressionStatement",
                  "src": "3995:33:1"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 654,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 650,
                      "name": "EXPIRATION",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 580,
                      "src": "4038:10:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "baseExpression": {
                        "argumentTypes": null,
                        "id": 651,
                        "name": "contractSpecs",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 616,
                        "src": "4051:13:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_array$_t_uint256_$7_memory_ptr",
                          "typeString": "uint256[7] memory"
                        }
                      },
                      "id": 653,
                      "indexExpression": {
                        "argumentTypes": null,
                        "hexValue": "36",
                        "id": 652,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "number",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "4065:1:1",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_rational_6_by_1",
                          "typeString": "int_const 6"
                        },
                        "value": "6"
                      },
                      "isConstant": false,
                      "isLValue": true,
                      "isPure": false,
                      "lValueRequested": false,
                      "nodeType": "IndexAccess",
                      "src": "4051:16:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "src": "4038:29:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "id": 655,
                  "nodeType": "ExpressionStatement",
                  "src": "4038:29:1"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "commonType": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        },
                        "id": 659,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "leftExpression": {
                          "argumentTypes": null,
                          "id": 657,
                          "name": "EXPIRATION",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 580,
                          "src": "4085:10:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        "nodeType": "BinaryOperation",
                        "operator": ">",
                        "rightExpression": {
                          "argumentTypes": null,
                          "id": 658,
                          "name": "now",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 3188,
                          "src": "4098:3:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        "src": "4085:16:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "hexValue": "45585049524154494f4e206d75737420626520696e2074686520667574757265",
                        "id": 660,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "string",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "4103:34:1",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_stringliteral_e8a0c6b62b433ce5e69c4b827408fddb2e8bfd75dae28294b58df77dac554510",
                          "typeString": "literal_string \"EXPIRATION must be in the future\""
                        },
                        "value": "EXPIRATION must be in the future"
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        },
                        {
                          "typeIdentifier": "t_stringliteral_e8a0c6b62b433ce5e69c4b827408fddb2e8bfd75dae28294b58df77dac554510",
                          "typeString": "literal_string \"EXPIRATION must be in the future\""
                        }
                      ],
                      "id": 656,
                      "name": "require",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [
                        3189,
                        3190
                      ],
                      "referencedDeclaration": 3190,
                      "src": "4077:7:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
                        "typeString": "function (bool,string memory) pure"
                      }
                    },
                    "id": 661,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "4077:61:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 662,
                  "nodeType": "ExpressionStatement",
                  "src": "4077:61:1"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "commonType": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        },
                        "id": 666,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "leftExpression": {
                          "argumentTypes": null,
                          "id": 664,
                          "name": "QTY_MULTIPLIER",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 572,
                          "src": "4156:14:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        "nodeType": "BinaryOperation",
                        "operator": "!=",
                        "rightExpression": {
                          "argumentTypes": null,
                          "hexValue": "30",
                          "id": 665,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": true,
                          "kind": "number",
                          "lValueRequested": false,
                          "nodeType": "Literal",
                          "src": "4174:1:1",
                          "subdenomination": null,
                          "typeDescriptions": {
                            "typeIdentifier": "t_rational_0_by_1",
                            "typeString": "int_const 0"
                          },
                          "value": "0"
                        },
                        "src": "4156:19:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "hexValue": "5154595f4d554c5449504c4945522063616e6e6f742062652030",
                        "id": 667,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "string",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "4176:28:1",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_stringliteral_748a5f570a3627d046bc2e571f821132aa05c98a3bc996fafedf936dd11ac6b6",
                          "typeString": "literal_string \"QTY_MULTIPLIER cannot be 0\""
                        },
                        "value": "QTY_MULTIPLIER cannot be 0"
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        },
                        {
                          "typeIdentifier": "t_stringliteral_748a5f570a3627d046bc2e571f821132aa05c98a3bc996fafedf936dd11ac6b6",
                          "typeString": "literal_string \"QTY_MULTIPLIER cannot be 0\""
                        }
                      ],
                      "id": 663,
                      "name": "require",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [
                        3189,
                        3190
                      ],
                      "referencedDeclaration": 3190,
                      "src": "4148:7:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
                        "typeString": "function (bool,string memory) pure"
                      }
                    },
                    "id": 668,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "4148:57:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 669,
                  "nodeType": "ExpressionStatement",
                  "src": "4148:57:1"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 674,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 670,
                      "name": "COLLATERAL_TOKEN_ADDRESS",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 562,
                      "src": "4216:24:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_address",
                        "typeString": "address"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "baseExpression": {
                        "argumentTypes": null,
                        "id": 671,
                        "name": "baseAddresses",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 612,
                        "src": "4243:13:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_array$_t_address_$3_memory_ptr",
                          "typeString": "address[3] memory"
                        }
                      },
                      "id": 673,
                      "indexExpression": {
                        "argumentTypes": null,
                        "hexValue": "31",
                        "id": 672,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "number",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "4257:1:1",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_rational_1_by_1",
                          "typeString": "int_const 1"
                        },
                        "value": "1"
                      },
                      "isConstant": false,
                      "isLValue": true,
                      "isPure": false,
                      "lValueRequested": false,
                      "nodeType": "IndexAccess",
                      "src": "4243:16:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_address",
                        "typeString": "address"
                      }
                    },
                    "src": "4216:43:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "id": 675,
                  "nodeType": "ExpressionStatement",
                  "src": "4216:43:1"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 680,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 676,
                      "name": "COLLATERAL_POOL_ADDRESS",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 564,
                      "src": "4269:23:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_address",
                        "typeString": "address"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "baseExpression": {
                        "argumentTypes": null,
                        "id": 677,
                        "name": "baseAddresses",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 612,
                        "src": "4295:13:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_array$_t_address_$3_memory_ptr",
                          "typeString": "address[3] memory"
                        }
                      },
                      "id": 679,
                      "indexExpression": {
                        "argumentTypes": null,
                        "hexValue": "32",
                        "id": 678,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "number",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "4309:1:1",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_rational_2_by_1",
                          "typeString": "int_const 2"
                        },
                        "value": "2"
                      },
                      "isConstant": false,
                      "isLValue": true,
                      "isPure": false,
                      "lValueRequested": false,
                      "nodeType": "IndexAccess",
                      "src": "4295:16:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_address",
                        "typeString": "address"
                      }
                    },
                    "src": "4269:42:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "id": 681,
                  "nodeType": "ExpressionStatement",
                  "src": "4269:42:1"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 689,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 682,
                      "name": "COLLATERAL_PER_UNIT",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 574,
                      "src": "4321:19:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "arguments": [
                        {
                          "argumentTypes": null,
                          "id": 685,
                          "name": "PRICE_FLOOR",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 568,
                          "src": "4376:11:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        {
                          "argumentTypes": null,
                          "id": 686,
                          "name": "PRICE_CAP",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 566,
                          "src": "4389:9:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        {
                          "argumentTypes": null,
                          "id": 687,
                          "name": "QTY_MULTIPLIER",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 572,
                          "src": "4400:14:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        }
                      ],
                      "expression": {
                        "argumentTypes": [
                          {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          },
                          {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          },
                          {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        ],
                        "expression": {
                          "argumentTypes": null,
                          "id": 683,
                          "name": "MathLib",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 1489,
                          "src": "4343:7:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_type$_t_contract$_MathLib_$1489_$",
                            "typeString": "type(library MathLib)"
                          }
                        },
                        "id": 684,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "memberName": "calculateTotalCollateral",
                        "nodeType": "MemberAccess",
                        "referencedDeclaration": 1455,
                        "src": "4343:32:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$_t_uint256_$returns$_t_uint256_$",
                          "typeString": "function (uint256,uint256,uint256) pure returns (uint256)"
                        }
                      },
                      "id": 688,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "functionCall",
                      "lValueRequested": false,
                      "names": [],
                      "nodeType": "FunctionCall",
                      "src": "4343:72:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "src": "4321:94:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "id": 690,
                  "nodeType": "ExpressionStatement",
                  "src": "4321:94:1"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 701,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 691,
                      "name": "COLLATERAL_TOKEN_FEE_PER_UNIT",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 576,
                      "src": "4425:29:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "arguments": [
                        {
                          "argumentTypes": null,
                          "id": 694,
                          "name": "PRICE_FLOOR",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 568,
                          "src": "4498:11:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        {
                          "argumentTypes": null,
                          "id": 695,
                          "name": "PRICE_CAP",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 566,
                          "src": "4523:9:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        {
                          "argumentTypes": null,
                          "id": 696,
                          "name": "QTY_MULTIPLIER",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 572,
                          "src": "4546:14:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        {
                          "argumentTypes": null,
                          "baseExpression": {
                            "argumentTypes": null,
                            "id": 697,
                            "name": "contractSpecs",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 616,
                            "src": "4574:13:1",
                            "typeDescriptions": {
                              "typeIdentifier": "t_array$_t_uint256_$7_memory_ptr",
                              "typeString": "uint256[7] memory"
                            }
                          },
                          "id": 699,
                          "indexExpression": {
                            "argumentTypes": null,
                            "hexValue": "34",
                            "id": 698,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": true,
                            "kind": "number",
                            "lValueRequested": false,
                            "nodeType": "Literal",
                            "src": "4588:1:1",
                            "subdenomination": null,
                            "typeDescriptions": {
                              "typeIdentifier": "t_rational_4_by_1",
                              "typeString": "int_const 4"
                            },
                            "value": "4"
                          },
                          "isConstant": false,
                          "isLValue": true,
                          "isPure": false,
                          "lValueRequested": false,
                          "nodeType": "IndexAccess",
                          "src": "4574:16:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        }
                      ],
                      "expression": {
                        "argumentTypes": [
                          {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          },
                          {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          },
                          {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          },
                          {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        ],
                        "expression": {
                          "argumentTypes": null,
                          "id": 692,
                          "name": "MathLib",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 1489,
                          "src": "4457:7:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_type$_t_contract$_MathLib_$1489_$",
                            "typeString": "type(library MathLib)"
                          }
                        },
                        "id": 693,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "memberName": "calculateFeePerUnit",
                        "nodeType": "MemberAccess",
                        "referencedDeclaration": 1488,
                        "src": "4457:27:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$returns$_t_uint256_$",
                          "typeString": "function (uint256,uint256,uint256,uint256) pure returns (uint256)"
                        }
                      },
                      "id": 700,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "functionCall",
                      "lValueRequested": false,
                      "names": [],
                      "nodeType": "FunctionCall",
                      "src": "4457:143:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "src": "4425:175:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "id": 702,
                  "nodeType": "ExpressionStatement",
                  "src": "4425:175:1"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 713,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 703,
                      "name": "MKT_TOKEN_FEE_PER_UNIT",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 578,
                      "src": "4610:22:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "arguments": [
                        {
                          "argumentTypes": null,
                          "id": 706,
                          "name": "PRICE_FLOOR",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 568,
                          "src": "4676:11:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        {
                          "argumentTypes": null,
                          "id": 707,
                          "name": "PRICE_CAP",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 566,
                          "src": "4701:9:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        {
                          "argumentTypes": null,
                          "id": 708,
                          "name": "QTY_MULTIPLIER",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 572,
                          "src": "4724:14:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        {
                          "argumentTypes": null,
                          "baseExpression": {
                            "argumentTypes": null,
                            "id": 709,
                            "name": "contractSpecs",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 616,
                            "src": "4752:13:1",
                            "typeDescriptions": {
                              "typeIdentifier": "t_array$_t_uint256_$7_memory_ptr",
                              "typeString": "uint256[7] memory"
                            }
                          },
                          "id": 711,
                          "indexExpression": {
                            "argumentTypes": null,
                            "hexValue": "35",
                            "id": 710,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": true,
                            "kind": "number",
                            "lValueRequested": false,
                            "nodeType": "Literal",
                            "src": "4766:1:1",
                            "subdenomination": null,
                            "typeDescriptions": {
                              "typeIdentifier": "t_rational_5_by_1",
                              "typeString": "int_const 5"
                            },
                            "value": "5"
                          },
                          "isConstant": false,
                          "isLValue": true,
                          "isPure": false,
                          "lValueRequested": false,
                          "nodeType": "IndexAccess",
                          "src": "4752:16:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        }
                      ],
                      "expression": {
                        "argumentTypes": [
                          {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          },
                          {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          },
                          {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          },
                          {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        ],
                        "expression": {
                          "argumentTypes": null,
                          "id": 704,
                          "name": "MathLib",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 1489,
                          "src": "4635:7:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_type$_t_contract$_MathLib_$1489_$",
                            "typeString": "type(library MathLib)"
                          }
                        },
                        "id": 705,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "memberName": "calculateFeePerUnit",
                        "nodeType": "MemberAccess",
                        "referencedDeclaration": 1488,
                        "src": "4635:27:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$returns$_t_uint256_$",
                          "typeString": "function (uint256,uint256,uint256,uint256) pure returns (uint256)"
                        }
                      },
                      "id": 712,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "functionCall",
                      "lValueRequested": false,
                      "names": [],
                      "nodeType": "FunctionCall",
                      "src": "4635:143:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "src": "4610:168:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "id": 714,
                  "nodeType": "ExpressionStatement",
                  "src": "4610:168:1"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 721,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 715,
                      "name": "CONTRACT_NAME",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 560,
                      "src": "4829:13:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_string_storage",
                        "typeString": "string storage ref"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "arguments": [],
                      "expression": {
                        "argumentTypes": [],
                        "expression": {
                          "argumentTypes": null,
                          "baseExpression": {
                            "argumentTypes": null,
                            "id": 716,
                            "name": "contractNames",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 608,
                            "src": "4845:13:1",
                            "typeDescriptions": {
                              "typeIdentifier": "t_array$_t_bytes32_$3_memory_ptr",
                              "typeString": "bytes32[3] memory"
                            }
                          },
                          "id": 718,
                          "indexExpression": {
                            "argumentTypes": null,
                            "hexValue": "30",
                            "id": 717,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": true,
                            "kind": "number",
                            "lValueRequested": false,
                            "nodeType": "Literal",
                            "src": "4859:1:1",
                            "subdenomination": null,
                            "typeDescriptions": {
                              "typeIdentifier": "t_rational_0_by_1",
                              "typeString": "int_const 0"
                            },
                            "value": "0"
                          },
                          "isConstant": false,
                          "isLValue": true,
                          "isPure": false,
                          "lValueRequested": false,
                          "nodeType": "IndexAccess",
                          "src": "4845:16:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_bytes32",
                            "typeString": "bytes32"
                          }
                        },
                        "id": 719,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "memberName": "bytes32ToString",
                        "nodeType": "MemberAccess",
                        "referencedDeclaration": 1529,
                        "src": "4845:32:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_function_internal_pure$_t_bytes32_$returns$_t_string_memory_ptr_$bound_to$_t_bytes32_$",
                          "typeString": "function (bytes32) pure returns (string memory)"
                        }
                      },
                      "id": 720,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "functionCall",
                      "lValueRequested": false,
                      "names": [],
                      "nodeType": "FunctionCall",
                      "src": "4845:34:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_string_memory_ptr",
                        "typeString": "string memory"
                      }
                    },
                    "src": "4829:50:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_string_storage",
                      "typeString": "string storage ref"
                    }
                  },
                  "id": 722,
                  "nodeType": "ExpressionStatement",
                  "src": "4829:50:1"
                },
                {
                  "assignments": [
                    724
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 724,
                      "name": "longPosToken",
                      "nodeType": "VariableDeclaration",
                      "scope": 775,
                      "src": "4889:26:1",
                      "stateVariable": false,
                      "storageLocation": "default",
                      "typeDescriptions": {
                        "typeIdentifier": "t_contract$_PositionToken_$2089",
                        "typeString": "contract PositionToken"
                      },
                      "typeName": {
                        "contractScope": null,
                        "id": 723,
                        "name": "PositionToken",
                        "nodeType": "UserDefinedTypeName",
                        "referencedDeclaration": 2089,
                        "src": "4889:13:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_contract$_PositionToken_$2089",
                          "typeString": "contract PositionToken"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 739,
                  "initialValue": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "hexValue": "4d41524b45542050726f746f636f6c204c6f6e6720506f736974696f6e20546f6b656e",
                        "id": 727,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "string",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "4949:37:1",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_stringliteral_dea80294dde7ccae15ed6914c7548c05f4e92f0b4f59b8de25e124060ecbb903",
                          "typeString": "literal_string \"MARKET Protocol Long Position Token\""
                        },
                        "value": "MARKET Protocol Long Position Token"
                      },
                      {
                        "argumentTypes": null,
                        "arguments": [],
                        "expression": {
                          "argumentTypes": [],
                          "expression": {
                            "argumentTypes": null,
                            "baseExpression": {
                              "argumentTypes": null,
                              "id": 728,
                              "name": "contractNames",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 608,
                              "src": "5000:13:1",
                              "typeDescriptions": {
                                "typeIdentifier": "t_array$_t_bytes32_$3_memory_ptr",
                                "typeString": "bytes32[3] memory"
                              }
                            },
                            "id": 730,
                            "indexExpression": {
                              "argumentTypes": null,
                              "hexValue": "31",
                              "id": 729,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": true,
                              "kind": "number",
                              "lValueRequested": false,
                              "nodeType": "Literal",
                              "src": "5014:1:1",
                              "subdenomination": null,
                              "typeDescriptions": {
                                "typeIdentifier": "t_rational_1_by_1",
                                "typeString": "int_const 1"
                              },
                              "value": "1"
                            },
                            "isConstant": false,
                            "isLValue": true,
                            "isPure": false,
                            "lValueRequested": false,
                            "nodeType": "IndexAccess",
                            "src": "5000:16:1",
                            "typeDescriptions": {
                              "typeIdentifier": "t_bytes32",
                              "typeString": "bytes32"
                            }
                          },
                          "id": 731,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "lValueRequested": false,
                          "memberName": "bytes32ToString",
                          "nodeType": "MemberAccess",
                          "referencedDeclaration": 1529,
                          "src": "5000:32:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_function_internal_pure$_t_bytes32_$returns$_t_string_memory_ptr_$bound_to$_t_bytes32_$",
                            "typeString": "function (bytes32) pure returns (string memory)"
                          }
                        },
                        "id": 732,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "kind": "functionCall",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "5000:34:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_string_memory_ptr",
                          "typeString": "string memory"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "arguments": [
                          {
                            "argumentTypes": null,
                            "expression": {
                              "argumentTypes": null,
                              "expression": {
                                "argumentTypes": null,
                                "id": 734,
                                "name": "PositionToken",
                                "nodeType": "Identifier",
                                "overloadedDeclarations": [],
                                "referencedDeclaration": 2089,
                                "src": "5054:13:1",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_type$_t_contract$_PositionToken_$2089_$",
                                  "typeString": "type(contract PositionToken)"
                                }
                              },
                              "id": 735,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "lValueRequested": false,
                              "memberName": "MarketSide",
                              "nodeType": "MemberAccess",
                              "referencedDeclaration": 2030,
                              "src": "5054:24:1",
                              "typeDescriptions": {
                                "typeIdentifier": "t_type$_t_enum$_MarketSide_$2030_$",
                                "typeString": "type(enum PositionToken.MarketSide)"
                              }
                            },
                            "id": 736,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": true,
                            "lValueRequested": false,
                            "memberName": "Long",
                            "nodeType": "MemberAccess",
                            "referencedDeclaration": null,
                            "src": "5054:29:1",
                            "typeDescriptions": {
                              "typeIdentifier": "t_enum$_MarketSide_$2030",
                              "typeString": "enum PositionToken.MarketSide"
                            }
                          }
                        ],
                        "expression": {
                          "argumentTypes": [
                            {
                              "typeIdentifier": "t_enum$_MarketSide_$2030",
                              "typeString": "enum PositionToken.MarketSide"
                            }
                          ],
                          "id": 733,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": true,
                          "lValueRequested": false,
                          "nodeType": "ElementaryTypeNameExpression",
                          "src": "5048:5:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_type$_t_uint8_$",
                            "typeString": "type(uint8)"
                          },
                          "typeName": "uint8"
                        },
                        "id": 737,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "typeConversion",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "5048:36:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint8",
                          "typeString": "uint8"
                        }
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_stringliteral_dea80294dde7ccae15ed6914c7548c05f4e92f0b4f59b8de25e124060ecbb903",
                          "typeString": "literal_string \"MARKET Protocol Long Position Token\""
                        },
                        {
                          "typeIdentifier": "t_string_memory_ptr",
                          "typeString": "string memory"
                        },
                        {
                          "typeIdentifier": "t_uint8",
                          "typeString": "uint8"
                        }
                      ],
                      "id": 726,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "nodeType": "NewExpression",
                      "src": "4918:17:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_creation_nonpayable$_t_string_memory_ptr_$_t_string_memory_ptr_$_t_uint8_$returns$_t_contract$_PositionToken_$2089_$",
                        "typeString": "function (string memory,string memory,uint8) returns (contract PositionToken)"
                      },
                      "typeName": {
                        "contractScope": null,
                        "id": 725,
                        "name": "PositionToken",
                        "nodeType": "UserDefinedTypeName",
                        "referencedDeclaration": 2089,
                        "src": "4922:13:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_contract$_PositionToken_$2089",
                          "typeString": "contract PositionToken"
                        }
                      }
                    },
                    "id": 738,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "4918:176:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_contract$_PositionToken_$2089",
                      "typeString": "contract PositionToken"
                    }
                  },
                  "nodeType": "VariableDeclarationStatement",
                  "src": "4889:205:1"
                },
                {
                  "assignments": [
                    741
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 741,
                      "name": "shortPosToken",
                      "nodeType": "VariableDeclaration",
                      "scope": 775,
                      "src": "5104:27:1",
                      "stateVariable": false,
                      "storageLocation": "default",
                      "typeDescriptions": {
                        "typeIdentifier": "t_contract$_PositionToken_$2089",
                        "typeString": "contract PositionToken"
                      },
                      "typeName": {
                        "contractScope": null,
                        "id": 740,
                        "name": "PositionToken",
                        "nodeType": "UserDefinedTypeName",
                        "referencedDeclaration": 2089,
                        "src": "5104:13:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_contract$_PositionToken_$2089",
                          "typeString": "contract PositionToken"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 756,
                  "initialValue": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "hexValue": "4d41524b45542050726f746f636f6c2053686f727420506f736974696f6e20546f6b656e",
                        "id": 744,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "string",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "5165:38:1",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_stringliteral_009c769d34a2b670483d4ea52ce57207c6951c5b1278318933e41fe97729c64f",
                          "typeString": "literal_string \"MARKET Protocol Short Position Token\""
                        },
                        "value": "MARKET Protocol Short Position Token"
                      },
                      {
                        "argumentTypes": null,
                        "arguments": [],
                        "expression": {
                          "argumentTypes": [],
                          "expression": {
                            "argumentTypes": null,
                            "baseExpression": {
                              "argumentTypes": null,
                              "id": 745,
                              "name": "contractNames",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 608,
                              "src": "5217:13:1",
                              "typeDescriptions": {
                                "typeIdentifier": "t_array$_t_bytes32_$3_memory_ptr",
                                "typeString": "bytes32[3] memory"
                              }
                            },
                            "id": 747,
                            "indexExpression": {
                              "argumentTypes": null,
                              "hexValue": "32",
                              "id": 746,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": true,
                              "kind": "number",
                              "lValueRequested": false,
                              "nodeType": "Literal",
                              "src": "5231:1:1",
                              "subdenomination": null,
                              "typeDescriptions": {
                                "typeIdentifier": "t_rational_2_by_1",
                                "typeString": "int_const 2"
                              },
                              "value": "2"
                            },
                            "isConstant": false,
                            "isLValue": true,
                            "isPure": false,
                            "lValueRequested": false,
                            "nodeType": "IndexAccess",
                            "src": "5217:16:1",
                            "typeDescriptions": {
                              "typeIdentifier": "t_bytes32",
                              "typeString": "bytes32"
                            }
                          },
                          "id": 748,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "lValueRequested": false,
                          "memberName": "bytes32ToString",
                          "nodeType": "MemberAccess",
                          "referencedDeclaration": 1529,
                          "src": "5217:32:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_function_internal_pure$_t_bytes32_$returns$_t_string_memory_ptr_$bound_to$_t_bytes32_$",
                            "typeString": "function (bytes32) pure returns (string memory)"
                          }
                        },
                        "id": 749,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "kind": "functionCall",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "5217:34:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_string_memory_ptr",
                          "typeString": "string memory"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "arguments": [
                          {
                            "argumentTypes": null,
                            "expression": {
                              "argumentTypes": null,
                              "expression": {
                                "argumentTypes": null,
                                "id": 751,
                                "name": "PositionToken",
                                "nodeType": "Identifier",
                                "overloadedDeclarations": [],
                                "referencedDeclaration": 2089,
                                "src": "5271:13:1",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_type$_t_contract$_PositionToken_$2089_$",
                                  "typeString": "type(contract PositionToken)"
                                }
                              },
                              "id": 752,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "lValueRequested": false,
                              "memberName": "MarketSide",
                              "nodeType": "MemberAccess",
                              "referencedDeclaration": 2030,
                              "src": "5271:24:1",
                              "typeDescriptions": {
                                "typeIdentifier": "t_type$_t_enum$_MarketSide_$2030_$",
                                "typeString": "type(enum PositionToken.MarketSide)"
                              }
                            },
                            "id": 753,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": true,
                            "lValueRequested": false,
                            "memberName": "Short",
                            "nodeType": "MemberAccess",
                            "referencedDeclaration": null,
                            "src": "5271:30:1",
                            "typeDescriptions": {
                              "typeIdentifier": "t_enum$_MarketSide_$2030",
                              "typeString": "enum PositionToken.MarketSide"
                            }
                          }
                        ],
                        "expression": {
                          "argumentTypes": [
                            {
                              "typeIdentifier": "t_enum$_MarketSide_$2030",
                              "typeString": "enum PositionToken.MarketSide"
                            }
                          ],
                          "id": 750,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": true,
                          "lValueRequested": false,
                          "nodeType": "ElementaryTypeNameExpression",
                          "src": "5265:5:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_type$_t_uint8_$",
                            "typeString": "type(uint8)"
                          },
                          "typeName": "uint8"
                        },
                        "id": 754,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "typeConversion",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "5265:37:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint8",
                          "typeString": "uint8"
                        }
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_stringliteral_009c769d34a2b670483d4ea52ce57207c6951c5b1278318933e41fe97729c64f",
                          "typeString": "literal_string \"MARKET Protocol Short Position Token\""
                        },
                        {
                          "typeIdentifier": "t_string_memory_ptr",
                          "typeString": "string memory"
                        },
                        {
                          "typeIdentifier": "t_uint8",
                          "typeString": "uint8"
                        }
                      ],
                      "id": 743,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "nodeType": "NewExpression",
                      "src": "5134:17:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_creation_nonpayable$_t_string_memory_ptr_$_t_string_memory_ptr_$_t_uint8_$returns$_t_contract$_PositionToken_$2089_$",
                        "typeString": "function (string memory,string memory,uint8) returns (contract PositionToken)"
                      },
                      "typeName": {
                        "contractScope": null,
                        "id": 742,
                        "name": "PositionToken",
                        "nodeType": "UserDefinedTypeName",
                        "referencedDeclaration": 2089,
                        "src": "5138:13:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_contract$_PositionToken_$2089",
                          "typeString": "contract PositionToken"
                        }
                      }
                    },
                    "id": 755,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "5134:178:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_contract$_PositionToken_$2089",
                      "typeString": "contract PositionToken"
                    }
                  },
                  "nodeType": "VariableDeclarationStatement",
                  "src": "5104:208:1"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 761,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 757,
                      "name": "LONG_POSITION_TOKEN",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 585,
                      "src": "5323:19:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_address",
                        "typeString": "address"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "arguments": [
                        {
                          "argumentTypes": null,
                          "id": 759,
                          "name": "longPosToken",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 724,
                          "src": "5353:12:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_contract$_PositionToken_$2089",
                            "typeString": "contract PositionToken"
                          }
                        }
                      ],
                      "expression": {
                        "argumentTypes": [
                          {
                            "typeIdentifier": "t_contract$_PositionToken_$2089",
                            "typeString": "contract PositionToken"
                          }
                        ],
                        "id": 758,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "lValueRequested": false,
                        "nodeType": "ElementaryTypeNameExpression",
                        "src": "5345:7:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_type$_t_address_$",
                          "typeString": "type(address)"
                        },
                        "typeName": "address"
                      },
                      "id": 760,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "typeConversion",
                      "lValueRequested": false,
                      "names": [],
                      "nodeType": "FunctionCall",
                      "src": "5345:21:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_address",
                        "typeString": "address"
                      }
                    },
                    "src": "5323:43:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "id": 762,
                  "nodeType": "ExpressionStatement",
                  "src": "5323:43:1"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 767,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 763,
                      "name": "SHORT_POSITION_TOKEN",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 587,
                      "src": "5376:20:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_address",
                        "typeString": "address"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "arguments": [
                        {
                          "argumentTypes": null,
                          "id": 765,
                          "name": "shortPosToken",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 741,
                          "src": "5407:13:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_contract$_PositionToken_$2089",
                            "typeString": "contract PositionToken"
                          }
                        }
                      ],
                      "expression": {
                        "argumentTypes": [
                          {
                            "typeIdentifier": "t_contract$_PositionToken_$2089",
                            "typeString": "contract PositionToken"
                          }
                        ],
                        "id": 764,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "lValueRequested": false,
                        "nodeType": "ElementaryTypeNameExpression",
                        "src": "5399:7:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_type$_t_address_$",
                          "typeString": "type(address)"
                        },
                        "typeName": "address"
                      },
                      "id": 766,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "typeConversion",
                      "lValueRequested": false,
                      "names": [],
                      "nodeType": "FunctionCall",
                      "src": "5399:22:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_address",
                        "typeString": "address"
                      }
                    },
                    "src": "5376:45:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "id": 768,
                  "nodeType": "ExpressionStatement",
                  "src": "5376:45:1"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "baseExpression": {
                          "argumentTypes": null,
                          "id": 770,
                          "name": "baseAddresses",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 612,
                          "src": "5450:13:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_array$_t_address_$3_memory_ptr",
                            "typeString": "address[3] memory"
                          }
                        },
                        "id": 772,
                        "indexExpression": {
                          "argumentTypes": null,
                          "hexValue": "30",
                          "id": 771,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": true,
                          "kind": "number",
                          "lValueRequested": false,
                          "nodeType": "Literal",
                          "src": "5464:1:1",
                          "subdenomination": null,
                          "typeDescriptions": {
                            "typeIdentifier": "t_rational_0_by_1",
                            "typeString": "int_const 0"
                          },
                          "value": "0"
                        },
                        "isConstant": false,
                        "isLValue": true,
                        "isPure": false,
                        "lValueRequested": false,
                        "nodeType": "IndexAccess",
                        "src": "5450:16:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        }
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        }
                      ],
                      "id": 769,
                      "name": "transferOwnership",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 2430,
                      "src": "5432:17:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_internal_nonpayable$_t_address_$returns$__$",
                        "typeString": "function (address)"
                      }
                    },
                    "id": 773,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "5432:35:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 774,
                  "nodeType": "ExpressionStatement",
                  "src": "5432:35:1"
                }
              ]
            },
            "documentation": "@param contractNames bytes32 array of names\n     contractName            name of the market contract\n     longTokenSymbol         symbol for the long token\n     shortTokenSymbol        symbol for the short token\n @param baseAddresses array of 2 addresses needed for our contract including:\n     ownerAddress                    address of the owner of these contracts.\n     collateralTokenAddress          address of the ERC20 token that will be used for collateral and pricing\n     collateralPoolAddress           address of our collateral pool contract\n @param contractSpecs array of unsigned integers including:\n     floorPrice          minimum tradeable price of this contract, contract enters settlement if breached\n     capPrice            maximum tradeable price of this contract, contract enters settlement if breached\n     priceDecimalPlaces  number of decimal places to convert our queried price from a floating point to\n                         an integer\n     qtyMultiplier       multiply traded qty by this value from base units of collateral token.\n     feeInBasisPoints    fee amount in basis points (Collateral token denominated) for minting.\n     mktFeeInBasisPoints fee amount in basis points (MKT denominated) for minting.\n     expirationTimeStamp seconds from epoch that this contract expires and enters settlement",
            "id": 776,
            "implemented": true,
            "kind": "constructor",
            "modifiers": [],
            "name": "",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 617,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 608,
                  "name": "contractNames",
                  "nodeType": "VariableDeclaration",
                  "scope": 776,
                  "src": "3641:31:1",
                  "stateVariable": false,
                  "storageLocation": "memory",
                  "typeDescriptions": {
                    "typeIdentifier": "t_array$_t_bytes32_$3_memory_ptr",
                    "typeString": "bytes32[3]"
                  },
                  "typeName": {
                    "baseType": {
                      "id": 605,
                      "name": "bytes32",
                      "nodeType": "ElementaryTypeName",
                      "src": "3641:7:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_bytes32",
                        "typeString": "bytes32"
                      }
                    },
                    "id": 607,
                    "length": {
                      "argumentTypes": null,
                      "hexValue": "33",
                      "id": 606,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "number",
                      "lValueRequested": false,
                      "nodeType": "Literal",
                      "src": "3649:1:1",
                      "subdenomination": null,
                      "typeDescriptions": {
                        "typeIdentifier": null,
                        "typeString": null
                      },
                      "value": "3"
                    },
                    "nodeType": "ArrayTypeName",
                    "src": "3641:10:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_array$_t_bytes32_$3_storage_ptr",
                      "typeString": "bytes32[3]"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 612,
                  "name": "baseAddresses",
                  "nodeType": "VariableDeclaration",
                  "scope": 776,
                  "src": "3682:31:1",
                  "stateVariable": false,
                  "storageLocation": "memory",
                  "typeDescriptions": {
                    "typeIdentifier": "t_array$_t_address_$3_memory_ptr",
                    "typeString": "address[3]"
                  },
                  "typeName": {
                    "baseType": {
                      "id": 609,
                      "name": "address",
                      "nodeType": "ElementaryTypeName",
                      "src": "3682:7:1",
                      "stateMutability": "nonpayable",
                      "typeDescriptions": {
                        "typeIdentifier": "t_address",
                        "typeString": "address"
                      }
                    },
                    "id": 611,
                    "length": {
                      "argumentTypes": null,
                      "hexValue": "33",
                      "id": 610,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "number",
                      "lValueRequested": false,
                      "nodeType": "Literal",
                      "src": "3690:1:1",
                      "subdenomination": null,
                      "typeDescriptions": {
                        "typeIdentifier": null,
                        "typeString": null
                      },
                      "value": "3"
                    },
                    "nodeType": "ArrayTypeName",
                    "src": "3682:10:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_array$_t_address_$3_storage_ptr",
                      "typeString": "address[3]"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 616,
                  "name": "contractSpecs",
                  "nodeType": "VariableDeclaration",
                  "scope": 776,
                  "src": "3723:28:1",
                  "stateVariable": false,
                  "storageLocation": "memory",
                  "typeDescriptions": {
                    "typeIdentifier": "t_array$_t_uint256_$7_memory_ptr",
                    "typeString": "uint256[7]"
                  },
                  "typeName": {
                    "baseType": {
                      "id": 613,
                      "name": "uint",
                      "nodeType": "ElementaryTypeName",
                      "src": "3723:4:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "id": 615,
                    "length": {
                      "argumentTypes": null,
                      "hexValue": "37",
                      "id": 614,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "number",
                      "lValueRequested": false,
                      "nodeType": "Literal",
                      "src": "3728:1:1",
                      "subdenomination": null,
                      "typeDescriptions": {
                        "typeIdentifier": null,
                        "typeString": null
                      },
                      "value": "7"
                    },
                    "nodeType": "ArrayTypeName",
                    "src": "3723:7:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_array$_t_uint256_$7_storage_ptr",
                      "typeString": "uint256[7]"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "3631:126:1"
            },
            "returnParameters": {
              "id": 618,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "3769:0:1"
            },
            "scope": 944,
            "src": "3620:1854:1",
            "stateMutability": "nonpayable",
            "superFunction": null,
            "visibility": "public"
          },
          {
            "body": {
              "id": 801,
              "nodeType": "Block",
              "src": "5901:244:1",
              "statements": [
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "id": 789,
                        "name": "qtyToMint",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 778,
                        "src": "6039:9:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "id": 790,
                        "name": "minter",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 780,
                        "src": "6050:6:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        }
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        },
                        {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        }
                      ],
                      "expression": {
                        "argumentTypes": null,
                        "arguments": [
                          {
                            "argumentTypes": null,
                            "id": 786,
                            "name": "LONG_POSITION_TOKEN",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 585,
                            "src": "6001:19:1",
                            "typeDescriptions": {
                              "typeIdentifier": "t_address",
                              "typeString": "address"
                            }
                          }
                        ],
                        "expression": {
                          "argumentTypes": [
                            {
                              "typeIdentifier": "t_address",
                              "typeString": "address"
                            }
                          ],
                          "id": 785,
                          "name": "PositionToken",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 2089,
                          "src": "5987:13:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_type$_t_contract$_PositionToken_$2089_$",
                            "typeString": "type(contract PositionToken)"
                          }
                        },
                        "id": 787,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "kind": "typeConversion",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "5987:34:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_contract$_PositionToken_$2089",
                          "typeString": "contract PositionToken"
                        }
                      },
                      "id": 788,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "memberName": "mintAndSendToken",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": 2073,
                      "src": "5987:51:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_external_nonpayable$_t_uint256_$_t_address_$returns$__$",
                        "typeString": "function (uint256,address) external"
                      }
                    },
                    "id": 791,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "5987:70:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 792,
                  "nodeType": "ExpressionStatement",
                  "src": "5987:70:1"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "id": 797,
                        "name": "qtyToMint",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 778,
                        "src": "6120:9:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "id": 798,
                        "name": "minter",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 780,
                        "src": "6131:6:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        }
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        },
                        {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        }
                      ],
                      "expression": {
                        "argumentTypes": null,
                        "arguments": [
                          {
                            "argumentTypes": null,
                            "id": 794,
                            "name": "SHORT_POSITION_TOKEN",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 587,
                            "src": "6081:20:1",
                            "typeDescriptions": {
                              "typeIdentifier": "t_address",
                              "typeString": "address"
                            }
                          }
                        ],
                        "expression": {
                          "argumentTypes": [
                            {
                              "typeIdentifier": "t_address",
                              "typeString": "address"
                            }
                          ],
                          "id": 793,
                          "name": "PositionToken",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 2089,
                          "src": "6067:13:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_type$_t_contract$_PositionToken_$2089_$",
                            "typeString": "type(contract PositionToken)"
                          }
                        },
                        "id": 795,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "kind": "typeConversion",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "6067:35:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_contract$_PositionToken_$2089",
                          "typeString": "contract PositionToken"
                        }
                      },
                      "id": 796,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "memberName": "mintAndSendToken",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": 2073,
                      "src": "6067:52:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_external_nonpayable$_t_uint256_$_t_address_$returns$__$",
                        "typeString": "function (uint256,address) external"
                      }
                    },
                    "id": 799,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "6067:71:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 800,
                  "nodeType": "ExpressionStatement",
                  "src": "6067:71:1"
                }
              ]
            },
            "documentation": "@notice called only by our collateral pool to create long and short position tokens\n @param qtyToMint    qty in base units of how many short and long tokens to mint\n @param minter       address of minter to receive tokens",
            "id": 802,
            "implemented": true,
            "kind": "function",
            "modifiers": [
              {
                "arguments": null,
                "id": 783,
                "modifierName": {
                  "argumentTypes": null,
                  "id": 782,
                  "name": "onlyCollateralPool",
                  "nodeType": "Identifier",
                  "overloadedDeclarations": [],
                  "referencedDeclaration": 943,
                  "src": "5878:18:1",
                  "typeDescriptions": {
                    "typeIdentifier": "t_modifier$__$",
                    "typeString": "modifier ()"
                  }
                },
                "nodeType": "ModifierInvocation",
                "src": "5878:18:1"
              }
            ],
            "name": "mintPositionTokens",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 781,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 778,
                  "name": "qtyToMint",
                  "nodeType": "VariableDeclaration",
                  "scope": 802,
                  "src": "5821:17:1",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 777,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "5821:7:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 780,
                  "name": "minter",
                  "nodeType": "VariableDeclaration",
                  "scope": 802,
                  "src": "5848:14:1",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_address",
                    "typeString": "address"
                  },
                  "typeName": {
                    "id": 779,
                    "name": "address",
                    "nodeType": "ElementaryTypeName",
                    "src": "5848:7:1",
                    "stateMutability": "nonpayable",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "5811:57:1"
            },
            "returnParameters": {
              "id": 784,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "5901:0:1"
            },
            "scope": 944,
            "src": "5784:361:1",
            "stateMutability": "nonpayable",
            "superFunction": null,
            "visibility": "external"
          },
          {
            "body": {
              "id": 819,
              "nodeType": "Block",
              "src": "6489:162:1",
              "statements": [
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "id": 815,
                        "name": "qtyToRedeem",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 804,
                        "src": "6622:11:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "id": 816,
                        "name": "redeemer",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 806,
                        "src": "6635:8:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        }
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        },
                        {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        }
                      ],
                      "expression": {
                        "argumentTypes": null,
                        "arguments": [
                          {
                            "argumentTypes": null,
                            "id": 812,
                            "name": "LONG_POSITION_TOKEN",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 585,
                            "src": "6589:19:1",
                            "typeDescriptions": {
                              "typeIdentifier": "t_address",
                              "typeString": "address"
                            }
                          }
                        ],
                        "expression": {
                          "argumentTypes": [
                            {
                              "typeIdentifier": "t_address",
                              "typeString": "address"
                            }
                          ],
                          "id": 811,
                          "name": "PositionToken",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 2089,
                          "src": "6575:13:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_type$_t_contract$_PositionToken_$2089_$",
                            "typeString": "type(contract PositionToken)"
                          }
                        },
                        "id": 813,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "kind": "typeConversion",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "6575:34:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_contract$_PositionToken_$2089",
                          "typeString": "contract PositionToken"
                        }
                      },
                      "id": 814,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "memberName": "redeemToken",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": 2088,
                      "src": "6575:46:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_external_nonpayable$_t_uint256_$_t_address_$returns$__$",
                        "typeString": "function (uint256,address) external"
                      }
                    },
                    "id": 817,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "6575:69:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 818,
                  "nodeType": "ExpressionStatement",
                  "src": "6575:69:1"
                }
              ]
            },
            "documentation": "@notice called only by our collateral pool to redeem long position tokens\n @param qtyToRedeem  qty in base units of how many tokens to redeem\n @param redeemer     address of person redeeming tokens",
            "id": 820,
            "implemented": true,
            "kind": "function",
            "modifiers": [
              {
                "arguments": null,
                "id": 809,
                "modifierName": {
                  "argumentTypes": null,
                  "id": 808,
                  "name": "onlyCollateralPool",
                  "nodeType": "Identifier",
                  "overloadedDeclarations": [],
                  "referencedDeclaration": 943,
                  "src": "6466:18:1",
                  "typeDescriptions": {
                    "typeIdentifier": "t_modifier$__$",
                    "typeString": "modifier ()"
                  }
                },
                "nodeType": "ModifierInvocation",
                "src": "6466:18:1"
              }
            ],
            "name": "redeemLongToken",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 807,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 804,
                  "name": "qtyToRedeem",
                  "nodeType": "VariableDeclaration",
                  "scope": 820,
                  "src": "6405:19:1",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 803,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "6405:7:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 806,
                  "name": "redeemer",
                  "nodeType": "VariableDeclaration",
                  "scope": 820,
                  "src": "6434:16:1",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_address",
                    "typeString": "address"
                  },
                  "typeName": {
                    "id": 805,
                    "name": "address",
                    "nodeType": "ElementaryTypeName",
                    "src": "6434:7:1",
                    "stateMutability": "nonpayable",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "6395:61:1"
            },
            "returnParameters": {
              "id": 810,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "6489:0:1"
            },
            "scope": 944,
            "src": "6371:280:1",
            "stateMutability": "nonpayable",
            "superFunction": null,
            "visibility": "external"
          },
          {
            "body": {
              "id": 837,
              "nodeType": "Block",
              "src": "6997:163:1",
              "statements": [
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "id": 833,
                        "name": "qtyToRedeem",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 822,
                        "src": "7131:11:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "id": 834,
                        "name": "redeemer",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 824,
                        "src": "7144:8:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        }
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        },
                        {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        }
                      ],
                      "expression": {
                        "argumentTypes": null,
                        "arguments": [
                          {
                            "argumentTypes": null,
                            "id": 830,
                            "name": "SHORT_POSITION_TOKEN",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 587,
                            "src": "7097:20:1",
                            "typeDescriptions": {
                              "typeIdentifier": "t_address",
                              "typeString": "address"
                            }
                          }
                        ],
                        "expression": {
                          "argumentTypes": [
                            {
                              "typeIdentifier": "t_address",
                              "typeString": "address"
                            }
                          ],
                          "id": 829,
                          "name": "PositionToken",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 2089,
                          "src": "7083:13:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_type$_t_contract$_PositionToken_$2089_$",
                            "typeString": "type(contract PositionToken)"
                          }
                        },
                        "id": 831,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "kind": "typeConversion",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "7083:35:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_contract$_PositionToken_$2089",
                          "typeString": "contract PositionToken"
                        }
                      },
                      "id": 832,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "memberName": "redeemToken",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": 2088,
                      "src": "7083:47:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_external_nonpayable$_t_uint256_$_t_address_$returns$__$",
                        "typeString": "function (uint256,address) external"
                      }
                    },
                    "id": 835,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "7083:70:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 836,
                  "nodeType": "ExpressionStatement",
                  "src": "7083:70:1"
                }
              ]
            },
            "documentation": "@notice called only by our collateral pool to redeem short position tokens\n @param qtyToRedeem  qty in base units of how many tokens to redeem\n @param redeemer     address of person redeeming tokens",
            "id": 838,
            "implemented": true,
            "kind": "function",
            "modifiers": [
              {
                "arguments": null,
                "id": 827,
                "modifierName": {
                  "argumentTypes": null,
                  "id": 826,
                  "name": "onlyCollateralPool",
                  "nodeType": "Identifier",
                  "overloadedDeclarations": [],
                  "referencedDeclaration": 943,
                  "src": "6974:18:1",
                  "typeDescriptions": {
                    "typeIdentifier": "t_modifier$__$",
                    "typeString": "modifier ()"
                  }
                },
                "nodeType": "ModifierInvocation",
                "src": "6974:18:1"
              }
            ],
            "name": "redeemShortToken",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 825,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 822,
                  "name": "qtyToRedeem",
                  "nodeType": "VariableDeclaration",
                  "scope": 838,
                  "src": "6913:19:1",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 821,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "6913:7:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 824,
                  "name": "redeemer",
                  "nodeType": "VariableDeclaration",
                  "scope": 838,
                  "src": "6942:16:1",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_address",
                    "typeString": "address"
                  },
                  "typeName": {
                    "id": 823,
                    "name": "address",
                    "nodeType": "ElementaryTypeName",
                    "src": "6942:7:1",
                    "stateMutability": "nonpayable",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "6903:61:1"
            },
            "returnParameters": {
              "id": 828,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "6997:0:1"
            },
            "scope": 944,
            "src": "6878:282:1",
            "stateMutability": "nonpayable",
            "superFunction": null,
            "visibility": "external"
          },
          {
            "body": {
              "id": 853,
              "nodeType": "Block",
              "src": "7360:86:1",
              "statements": [
                {
                  "expression": {
                    "argumentTypes": null,
                    "commonType": {
                      "typeIdentifier": "t_bool",
                      "typeString": "bool"
                    },
                    "id": 851,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftExpression": {
                      "argumentTypes": null,
                      "id": 843,
                      "name": "isSettled",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 596,
                      "src": "7377:9:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_bool",
                        "typeString": "bool"
                      }
                    },
                    "nodeType": "BinaryOperation",
                    "operator": "&&",
                    "rightExpression": {
                      "argumentTypes": null,
                      "components": [
                        {
                          "argumentTypes": null,
                          "commonType": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          },
                          "id": 849,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "lValueRequested": false,
                          "leftExpression": {
                            "argumentTypes": null,
                            "id": 844,
                            "name": "now",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 3188,
                            "src": "7391:3:1",
                            "typeDescriptions": {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          },
                          "nodeType": "BinaryOperation",
                          "operator": ">=",
                          "rightExpression": {
                            "argumentTypes": null,
                            "components": [
                              {
                                "argumentTypes": null,
                                "commonType": {
                                  "typeIdentifier": "t_uint256",
                                  "typeString": "uint256"
                                },
                                "id": 847,
                                "isConstant": false,
                                "isLValue": false,
                                "isPure": false,
                                "lValueRequested": false,
                                "leftExpression": {
                                  "argumentTypes": null,
                                  "id": 845,
                                  "name": "settlementTimeStamp",
                                  "nodeType": "Identifier",
                                  "overloadedDeclarations": [],
                                  "referencedDeclaration": 593,
                                  "src": "7399:19:1",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_uint256",
                                    "typeString": "uint256"
                                  }
                                },
                                "nodeType": "BinaryOperation",
                                "operator": "+",
                                "rightExpression": {
                                  "argumentTypes": null,
                                  "id": 846,
                                  "name": "SETTLEMENT_DELAY",
                                  "nodeType": "Identifier",
                                  "overloadedDeclarations": [],
                                  "referencedDeclaration": 583,
                                  "src": "7421:16:1",
                                  "typeDescriptions": {
                                    "typeIdentifier": "t_uint256",
                                    "typeString": "uint256"
                                  }
                                },
                                "src": "7399:38:1",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_uint256",
                                  "typeString": "uint256"
                                }
                              }
                            ],
                            "id": 848,
                            "isConstant": false,
                            "isInlineArray": false,
                            "isLValue": false,
                            "isPure": false,
                            "lValueRequested": false,
                            "nodeType": "TupleExpression",
                            "src": "7398:40:1",
                            "typeDescriptions": {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          },
                          "src": "7391:47:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_bool",
                            "typeString": "bool"
                          }
                        }
                      ],
                      "id": 850,
                      "isConstant": false,
                      "isInlineArray": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "nodeType": "TupleExpression",
                      "src": "7390:49:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_bool",
                        "typeString": "bool"
                      }
                    },
                    "src": "7377:62:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_bool",
                      "typeString": "bool"
                    }
                  },
                  "functionReturnParameters": 842,
                  "id": 852,
                  "nodeType": "Return",
                  "src": "7370:69:1"
                }
              ]
            },
            "documentation": "@notice checks to see if a contract is settled, and that the settlement delay has passed",
            "id": 854,
            "implemented": true,
            "kind": "function",
            "modifiers": [],
            "name": "isPostSettlementDelay",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 839,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "7330:2:1"
            },
            "returnParameters": {
              "id": 842,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 841,
                  "name": "",
                  "nodeType": "VariableDeclaration",
                  "scope": 854,
                  "src": "7354:4:1",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_bool",
                    "typeString": "bool"
                  },
                  "typeName": {
                    "id": 840,
                    "name": "bool",
                    "nodeType": "ElementaryTypeName",
                    "src": "7354:4:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_bool",
                      "typeString": "bool"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "7353:6:1"
            },
            "scope": 944,
            "src": "7300:146:1",
            "stateMutability": "view",
            "superFunction": null,
            "visibility": "public"
          },
          {
            "body": {
              "id": 912,
              "nodeType": "Block",
              "src": "7699:830:1",
              "statements": [
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "id": 859,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "nodeType": "UnaryOperation",
                        "operator": "!",
                        "prefix": true,
                        "src": "7717:10:1",
                        "subExpression": {
                          "argumentTypes": null,
                          "id": 858,
                          "name": "isSettled",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 596,
                          "src": "7718:9:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_bool",
                            "typeString": "bool"
                          }
                        },
                        "typeDescriptions": {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "hexValue": "436f6e747261637420697320616c726561647920736574746c6564",
                        "id": 860,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "string",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "7729:29:1",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_stringliteral_ca173d03a4252dfa571f586cd2c07cbf7461ad4fb4aa3d483d41782466df287b",
                          "typeString": "literal_string \"Contract is already settled\""
                        },
                        "value": "Contract is already settled"
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        },
                        {
                          "typeIdentifier": "t_stringliteral_ca173d03a4252dfa571f586cd2c07cbf7461ad4fb4aa3d483d41782466df287b",
                          "typeString": "literal_string \"Contract is already settled\""
                        }
                      ],
                      "id": 857,
                      "name": "require",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [
                        3189,
                        3190
                      ],
                      "referencedDeclaration": 3190,
                      "src": "7709:7:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
                        "typeString": "function (bool,string memory) pure"
                      }
                    },
                    "id": 861,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "7709:50:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 862,
                  "nodeType": "ExpressionStatement",
                  "src": "7709:50:1"
                },
                {
                  "assignments": [
                    864
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 864,
                      "name": "newSettlementPrice",
                      "nodeType": "VariableDeclaration",
                      "scope": 912,
                      "src": "7790:23:1",
                      "stateVariable": false,
                      "storageLocation": "default",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      },
                      "typeName": {
                        "id": 863,
                        "name": "uint",
                        "nodeType": "ElementaryTypeName",
                        "src": "7790:4:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 865,
                  "initialValue": null,
                  "nodeType": "VariableDeclarationStatement",
                  "src": "7790:23:1"
                },
                {
                  "condition": {
                    "argumentTypes": null,
                    "commonType": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    },
                    "id": 868,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftExpression": {
                      "argumentTypes": null,
                      "id": 866,
                      "name": "now",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 3188,
                      "src": "7827:3:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "BinaryOperation",
                    "operator": ">",
                    "rightExpression": {
                      "argumentTypes": null,
                      "id": 867,
                      "name": "EXPIRATION",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 580,
                      "src": "7833:10:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "src": "7827:16:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_bool",
                      "typeString": "bool"
                    }
                  },
                  "falseBody": {
                    "condition": {
                      "argumentTypes": null,
                      "commonType": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      },
                      "id": 880,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "leftExpression": {
                        "argumentTypes": null,
                        "id": 878,
                        "name": "lastPrice",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 589,
                        "src": "8078:9:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "nodeType": "BinaryOperation",
                      "operator": ">=",
                      "rightExpression": {
                        "argumentTypes": null,
                        "id": 879,
                        "name": "PRICE_CAP",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 566,
                        "src": "8091:9:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "src": "8078:22:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_bool",
                        "typeString": "bool"
                      }
                    },
                    "falseBody": {
                      "condition": {
                        "argumentTypes": null,
                        "commonType": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        },
                        "id": 892,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "leftExpression": {
                          "argumentTypes": null,
                          "id": 890,
                          "name": "lastPrice",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 589,
                          "src": "8261:9:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        "nodeType": "BinaryOperation",
                        "operator": "<=",
                        "rightExpression": {
                          "argumentTypes": null,
                          "id": 891,
                          "name": "PRICE_FLOOR",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 568,
                          "src": "8274:11:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        "src": "8261:24:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        }
                      },
                      "falseBody": null,
                      "id": 902,
                      "nodeType": "IfStatement",
                      "src": "8257:182:1",
                      "trueBody": {
                        "id": 901,
                        "nodeType": "Block",
                        "src": "8287:152:1",
                        "statements": [
                          {
                            "expression": {
                              "argumentTypes": null,
                              "id": 895,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "lValueRequested": false,
                              "leftHandSide": {
                                "argumentTypes": null,
                                "id": 893,
                                "name": "isSettled",
                                "nodeType": "Identifier",
                                "overloadedDeclarations": [],
                                "referencedDeclaration": 596,
                                "src": "8366:9:1",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_bool",
                                  "typeString": "bool"
                                }
                              },
                              "nodeType": "Assignment",
                              "operator": "=",
                              "rightHandSide": {
                                "argumentTypes": null,
                                "hexValue": "74727565",
                                "id": 894,
                                "isConstant": false,
                                "isLValue": false,
                                "isPure": true,
                                "kind": "bool",
                                "lValueRequested": false,
                                "nodeType": "Literal",
                                "src": "8378:4:1",
                                "subdenomination": null,
                                "typeDescriptions": {
                                  "typeIdentifier": "t_bool",
                                  "typeString": "bool"
                                },
                                "value": "true"
                              },
                              "src": "8366:16:1",
                              "typeDescriptions": {
                                "typeIdentifier": "t_bool",
                                "typeString": "bool"
                              }
                            },
                            "id": 896,
                            "nodeType": "ExpressionStatement",
                            "src": "8366:16:1"
                          },
                          {
                            "expression": {
                              "argumentTypes": null,
                              "id": 899,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "lValueRequested": false,
                              "leftHandSide": {
                                "argumentTypes": null,
                                "id": 897,
                                "name": "newSettlementPrice",
                                "nodeType": "Identifier",
                                "overloadedDeclarations": [],
                                "referencedDeclaration": 864,
                                "src": "8396:18:1",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_uint256",
                                  "typeString": "uint256"
                                }
                              },
                              "nodeType": "Assignment",
                              "operator": "=",
                              "rightHandSide": {
                                "argumentTypes": null,
                                "id": 898,
                                "name": "PRICE_FLOOR",
                                "nodeType": "Identifier",
                                "overloadedDeclarations": [],
                                "referencedDeclaration": 568,
                                "src": "8417:11:1",
                                "typeDescriptions": {
                                  "typeIdentifier": "t_uint256",
                                  "typeString": "uint256"
                                }
                              },
                              "src": "8396:32:1",
                              "typeDescriptions": {
                                "typeIdentifier": "t_uint256",
                                "typeString": "uint256"
                              }
                            },
                            "id": 900,
                            "nodeType": "ExpressionStatement",
                            "src": "8396:32:1"
                          }
                        ]
                      }
                    },
                    "id": 903,
                    "nodeType": "IfStatement",
                    "src": "8074:365:1",
                    "trueBody": {
                      "id": 889,
                      "nodeType": "Block",
                      "src": "8102:149:1",
                      "statements": [
                        {
                          "expression": {
                            "argumentTypes": null,
                            "id": 883,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": false,
                            "lValueRequested": false,
                            "leftHandSide": {
                              "argumentTypes": null,
                              "id": 881,
                              "name": "isSettled",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 596,
                              "src": "8180:9:1",
                              "typeDescriptions": {
                                "typeIdentifier": "t_bool",
                                "typeString": "bool"
                              }
                            },
                            "nodeType": "Assignment",
                            "operator": "=",
                            "rightHandSide": {
                              "argumentTypes": null,
                              "hexValue": "74727565",
                              "id": 882,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": true,
                              "kind": "bool",
                              "lValueRequested": false,
                              "nodeType": "Literal",
                              "src": "8192:4:1",
                              "subdenomination": null,
                              "typeDescriptions": {
                                "typeIdentifier": "t_bool",
                                "typeString": "bool"
                              },
                              "value": "true"
                            },
                            "src": "8180:16:1",
                            "typeDescriptions": {
                              "typeIdentifier": "t_bool",
                              "typeString": "bool"
                            }
                          },
                          "id": 884,
                          "nodeType": "ExpressionStatement",
                          "src": "8180:16:1"
                        },
                        {
                          "expression": {
                            "argumentTypes": null,
                            "id": 887,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": false,
                            "lValueRequested": false,
                            "leftHandSide": {
                              "argumentTypes": null,
                              "id": 885,
                              "name": "newSettlementPrice",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 864,
                              "src": "8210:18:1",
                              "typeDescriptions": {
                                "typeIdentifier": "t_uint256",
                                "typeString": "uint256"
                              }
                            },
                            "nodeType": "Assignment",
                            "operator": "=",
                            "rightHandSide": {
                              "argumentTypes": null,
                              "id": 886,
                              "name": "PRICE_CAP",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 566,
                              "src": "8231:9:1",
                              "typeDescriptions": {
                                "typeIdentifier": "t_uint256",
                                "typeString": "uint256"
                              }
                            },
                            "src": "8210:30:1",
                            "typeDescriptions": {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          },
                          "id": 888,
                          "nodeType": "ExpressionStatement",
                          "src": "8210:30:1"
                        }
                      ]
                    }
                  },
                  "id": 904,
                  "nodeType": "IfStatement",
                  "src": "7823:616:1",
                  "trueBody": {
                    "id": 877,
                    "nodeType": "Block",
                    "src": "7845:223:1",
                    "statements": [
                      {
                        "expression": {
                          "argumentTypes": null,
                          "id": 871,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "lValueRequested": false,
                          "leftHandSide": {
                            "argumentTypes": null,
                            "id": 869,
                            "name": "isSettled",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 596,
                            "src": "7940:9:1",
                            "typeDescriptions": {
                              "typeIdentifier": "t_bool",
                              "typeString": "bool"
                            }
                          },
                          "nodeType": "Assignment",
                          "operator": "=",
                          "rightHandSide": {
                            "argumentTypes": null,
                            "hexValue": "74727565",
                            "id": 870,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": true,
                            "kind": "bool",
                            "lValueRequested": false,
                            "nodeType": "Literal",
                            "src": "7952:4:1",
                            "subdenomination": null,
                            "typeDescriptions": {
                              "typeIdentifier": "t_bool",
                              "typeString": "bool"
                            },
                            "value": "true"
                          },
                          "src": "7940:16:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_bool",
                            "typeString": "bool"
                          }
                        },
                        "id": 872,
                        "nodeType": "ExpressionStatement",
                        "src": "7940:16:1"
                      },
                      {
                        "expression": {
                          "argumentTypes": null,
                          "id": 875,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "lValueRequested": false,
                          "leftHandSide": {
                            "argumentTypes": null,
                            "id": 873,
                            "name": "newSettlementPrice",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 864,
                            "src": "8027:18:1",
                            "typeDescriptions": {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          },
                          "nodeType": "Assignment",
                          "operator": "=",
                          "rightHandSide": {
                            "argumentTypes": null,
                            "id": 874,
                            "name": "lastPrice",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 589,
                            "src": "8048:9:1",
                            "typeDescriptions": {
                              "typeIdentifier": "t_uint256",
                              "typeString": "uint256"
                            }
                          },
                          "src": "8027:30:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_uint256",
                            "typeString": "uint256"
                          }
                        },
                        "id": 876,
                        "nodeType": "ExpressionStatement",
                        "src": "8027:30:1"
                      }
                    ]
                  }
                },
                {
                  "condition": {
                    "argumentTypes": null,
                    "id": 905,
                    "name": "isSettled",
                    "nodeType": "Identifier",
                    "overloadedDeclarations": [],
                    "referencedDeclaration": 596,
                    "src": "8453:9:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_bool",
                      "typeString": "bool"
                    }
                  },
                  "falseBody": null,
                  "id": 911,
                  "nodeType": "IfStatement",
                  "src": "8449:74:1",
                  "trueBody": {
                    "id": 910,
                    "nodeType": "Block",
                    "src": "8464:59:1",
                    "statements": [
                      {
                        "expression": {
                          "argumentTypes": null,
                          "arguments": [
                            {
                              "argumentTypes": null,
                              "id": 907,
                              "name": "newSettlementPrice",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 864,
                              "src": "8493:18:1",
                              "typeDescriptions": {
                                "typeIdentifier": "t_uint256",
                                "typeString": "uint256"
                              }
                            }
                          ],
                          "expression": {
                            "argumentTypes": [
                              {
                                "typeIdentifier": "t_uint256",
                                "typeString": "uint256"
                              }
                            ],
                            "id": 906,
                            "name": "settleContract",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 931,
                            "src": "8478:14:1",
                            "typeDescriptions": {
                              "typeIdentifier": "t_function_internal_nonpayable$_t_uint256_$returns$__$",
                              "typeString": "function (uint256)"
                            }
                          },
                          "id": 908,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "kind": "functionCall",
                          "lValueRequested": false,
                          "names": [],
                          "nodeType": "FunctionCall",
                          "src": "8478:34:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_tuple$__$",
                            "typeString": "tuple()"
                          }
                        },
                        "id": 909,
                        "nodeType": "ExpressionStatement",
                        "src": "8478:34:1"
                      }
                    ]
                  }
                }
              ]
            },
            "documentation": "@dev checks our last query price to see if our contract should enter settlement due to it being past our",
            "id": 913,
            "implemented": true,
            "kind": "function",
            "modifiers": [],
            "name": "checkSettlement",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 855,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "7687:2:1"
            },
            "returnParameters": {
              "id": 856,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "7699:0:1"
            },
            "scope": 944,
            "src": "7663:866:1",
            "stateMutability": "nonpayable",
            "superFunction": null,
            "visibility": "internal"
          },
          {
            "body": {
              "id": 930,
              "nodeType": "Block",
              "src": "8744:142:1",
              "statements": [
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 920,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 918,
                      "name": "settlementTimeStamp",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 593,
                      "src": "8754:19:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "id": 919,
                      "name": "now",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 3188,
                      "src": "8776:3:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "src": "8754:25:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "id": 921,
                  "nodeType": "ExpressionStatement",
                  "src": "8754:25:1"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 924,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 922,
                      "name": "settlementPrice",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 591,
                      "src": "8789:15:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "id": 923,
                      "name": "finalSettlementPrice",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 915,
                      "src": "8807:20:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "src": "8789:38:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "id": 925,
                  "nodeType": "ExpressionStatement",
                  "src": "8789:38:1"
                },
                {
                  "eventCall": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "id": 927,
                        "name": "finalSettlementPrice",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 915,
                        "src": "8858:20:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      ],
                      "id": 926,
                      "name": "ContractSettled",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 604,
                      "src": "8842:15:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_event_nonpayable$_t_uint256_$returns$__$",
                        "typeString": "function (uint256)"
                      }
                    },
                    "id": 928,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "8842:37:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 929,
                  "nodeType": "EmitStatement",
                  "src": "8837:42:1"
                }
              ]
            },
            "documentation": "@dev records our final settlement price and fires needed events.\n @param finalSettlementPrice final query price at time of settlement",
            "id": 931,
            "implemented": true,
            "kind": "function",
            "modifiers": [],
            "name": "settleContract",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 916,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 915,
                  "name": "finalSettlementPrice",
                  "nodeType": "VariableDeclaration",
                  "scope": 931,
                  "src": "8708:25:1",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 914,
                    "name": "uint",
                    "nodeType": "ElementaryTypeName",
                    "src": "8708:4:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "8707:27:1"
            },
            "returnParameters": {
              "id": 917,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "8744:0:1"
            },
            "scope": 944,
            "src": "8684:202:1",
            "stateMutability": "nonpayable",
            "superFunction": null,
            "visibility": "internal"
          },
          {
            "body": {
              "id": 942,
              "nodeType": "Block",
              "src": "9053:116:1",
              "statements": [
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "commonType": {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        },
                        "id": 937,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "leftExpression": {
                          "argumentTypes": null,
                          "expression": {
                            "argumentTypes": null,
                            "id": 934,
                            "name": "msg",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 3186,
                            "src": "9071:3:1",
                            "typeDescriptions": {
                              "typeIdentifier": "t_magic_message",
                              "typeString": "msg"
                            }
                          },
                          "id": 935,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "lValueRequested": false,
                          "memberName": "sender",
                          "nodeType": "MemberAccess",
                          "referencedDeclaration": null,
                          "src": "9071:10:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_address_payable",
                            "typeString": "address payable"
                          }
                        },
                        "nodeType": "BinaryOperation",
                        "operator": "==",
                        "rightExpression": {
                          "argumentTypes": null,
                          "id": 936,
                          "name": "COLLATERAL_POOL_ADDRESS",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 564,
                          "src": "9085:23:1",
                          "typeDescriptions": {
                            "typeIdentifier": "t_address",
                            "typeString": "address"
                          }
                        },
                        "src": "9071:37:1",
                        "typeDescriptions": {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "hexValue": "4f6e6c792063616c6c61626c652066726f6d2074686520636f6c6c61746572616c20706f6f6c",
                        "id": 938,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "string",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "9110:40:1",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_stringliteral_01055747720d725252280235b71e0d12366d812b78ea07163258ecbeba48bae5",
                          "typeString": "literal_string \"Only callable from the collateral pool\""
                        },
                        "value": "Only callable from the collateral pool"
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        },
                        {
                          "typeIdentifier": "t_stringliteral_01055747720d725252280235b71e0d12366d812b78ea07163258ecbeba48bae5",
                          "typeString": "literal_string \"Only callable from the collateral pool\""
                        }
                      ],
                      "id": 933,
                      "name": "require",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [
                        3189,
                        3190
                      ],
                      "referencedDeclaration": 3190,
                      "src": "9063:7:1",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
                        "typeString": "function (bool,string memory) pure"
                      }
                    },
                    "id": 939,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "9063:88:1",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 940,
                  "nodeType": "ExpressionStatement",
                  "src": "9063:88:1"
                },
                {
                  "id": 941,
                  "nodeType": "PlaceholderStatement",
                  "src": "9161:1:1"
                }
              ]
            },
            "documentation": "@notice only able to be called directly by our collateral pool which controls the position tokens\n for this contract!",
            "id": 943,
            "name": "onlyCollateralPool",
            "nodeType": "ModifierDefinition",
            "parameters": {
              "id": 932,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "9053:0:1"
            },
            "src": "9025:144:1",
            "visibility": "internal"
          }
        ],
        "scope": 945,
        "src": "1076:8096:1"
      }
    ],
    "src": "608:8565:1"
  },
  "compiler": {
    "name": "solc",
    "version": "0.5.2+commit.1df8f40c.Emscripten.clang"
  },
  "networks": {},
  "schemaVersion": "3.0.9",
  "updatedAt": "2019-05-28T23:53:01.576Z",
  "devdoc": {
    "author": "Phil Elsasser <phil@marketprotocol.io>",
    "methods": {
      "constructor": {
        "params": {
          "baseAddresses": "array of 2 addresses needed for our contract including:     ownerAddress                    address of the owner of these contracts.     collateralTokenAddress          address of the ERC20 token that will be used for collateral and pricing     collateralPoolAddress           address of our collateral pool contract",
          "contractNames": "bytes32 array of names     contractName            name of the market contract     longTokenSymbol         symbol for the long token     shortTokenSymbol        symbol for the short token",
          "contractSpecs": "array of unsigned integers including:     floorPrice          minimum tradeable price of this contract, contract enters settlement if breached     capPrice            maximum tradeable price of this contract, contract enters settlement if breached     priceDecimalPlaces  number of decimal places to convert our queried price from a floating point to                         an integer     qtyMultiplier       multiply traded qty by this value from base units of collateral token.     feeInBasisPoints    fee amount in basis points (Collateral token denominated) for minting.     mktFeeInBasisPoints fee amount in basis points (MKT denominated) for minting.     expirationTimeStamp seconds from epoch that this contract expires and enters settlement"
        }
      },
      "isOwner()": {
        "return": "true if `msg.sender` is the owner of the contract."
      },
      "mintPositionTokens(uint256,address)": {
        "params": {
          "minter": "address of minter to receive tokens",
          "qtyToMint": "qty in base units of how many short and long tokens to mint"
        }
      },
      "owner()": {
        "return": "the address of the owner."
      },
      "redeemLongToken(uint256,address)": {
        "params": {
          "qtyToRedeem": "qty in base units of how many tokens to redeem",
          "redeemer": "address of person redeeming tokens"
        }
      },
      "redeemShortToken(uint256,address)": {
        "params": {
          "qtyToRedeem": "qty in base units of how many tokens to redeem",
          "redeemer": "address of person redeeming tokens"
        }
      },
      "renounceOwnership()": {
        "details": "Allows the current owner to relinquish control of the contract. It will not be possible to call the functions with the `onlyOwner` modifier anymore."
      },
      "transferOwnership(address)": {
        "details": "Allows the current owner to transfer control of the contract to a newOwner.",
        "params": {
          "newOwner": "The address to transfer ownership to."
        }
      }
    },
    "title": "MarketContract base contract implement all needed functionality for trading."
  },
  "userdoc": {
    "methods": {
      "isPostSettlementDelay()": {
        "notice": "checks to see if a contract is settled, and that the settlement delay has passed"
      },
      "mintPositionTokens(uint256,address)": {
        "notice": "called only by our collateral pool to create long and short position tokens"
      },
      "redeemLongToken(uint256,address)": {
        "notice": "called only by our collateral pool to redeem long position tokens"
      },
      "redeemShortToken(uint256,address)": {
        "notice": "called only by our collateral pool to redeem short position tokens"
      },
      "renounceOwnership()": {
        "notice": "Renouncing ownership will leave the contract without an owner, thereby removing any functionality that is only available to the owner."
      }
    },
    "notice": "this is the abstract base contract that all contracts should inherit from to implement different oracle solutions."
  }
}