Predictions contract
Methods
approve
function approve(address to, uint256 tokenId) external nonpayable
Parameters
| Name | Type | Description |
|---|---|---|
| to | address | undefined |
| tokenId | uint256 | undefined |
approveOracle
function approveOracle(address oracle, bool isTrusted) external nonpayable
Parameters
| Name | Type | Description |
|---|---|---|
| oracle | address | undefined |
| isTrusted | bool | undefined |
balanceOf
function balanceOf(address owner) external view returns (uint256)
Parameters
| Name | Type | Description |
|---|---|---|
| owner | address | undefined |
Returns
| Name | Type | Description |
|---|---|---|
| _0 | uint256 | undefined |
burnPredictionToIncreaseOpenPredictionsCount
function burnPredictionToIncreaseOpenPredictionsCount(uint256 predictionID) external nonpayable
Parameters
| Name | Type | Description |
|---|---|---|
| predictionID | uint256 | undefined |
cancelPrediction
function cancelPrediction(uint256 predictionID) external nonpayable
Parameters
| Name | Type | Description |
|---|---|---|
| predictionID | uint256 | undefined |
cancelPredictions
function cancelPredictions(uint256[] predictionIDs) external nonpayable
Parameters
| Name | Type | Description |
|---|---|---|
| predictionIDs | uint256[] | undefined |
changeCompetitionsAddress
function changeCompetitionsAddress(address newCompetitionsAddress) external nonpayable
Parameters
| Name | Type | Description |
|---|---|---|
| newCompetitionsAddress | address | undefined |
changeDurationToClosePredictions
function changeDurationToClosePredictions(uint256 newDurationToClosePredictions) external nonpayable
Parameters
| Name | Type | Description |
|---|---|---|
| newDurationToClosePredictions | uint256 | undefined |
changeMaxLeverage
function changeMaxLeverage(uint256 newMaxLeverage) external nonpayable
Parameters
| Name | Type | Description |
|---|---|---|
| newMaxLeverage | uint256 | undefined |
changeMaxOpenPredictionsCount
function changeMaxOpenPredictionsCount(uint256 newMaxOpenPredictionsCount) external nonpayable
Parameters
| Name | Type | Description |
|---|---|---|
| newMaxOpenPredictionsCount | uint256 | undefined |
changePrediction
function changePrediction(uint256 predictionID, uint256 stopLossPrice, uint256 takeProfitPrice) external nonpayable
Parameters
| Name | Type | Description |
|---|---|---|
| predictionID | uint256 | undefined |
| stopLossPrice | uint256 | undefined |
| takeProfitPrice | uint256 | undefined |
changePredictions
function changePredictions(uint256[] predictionIDs, uint256[] stopLossPrice, uint256[] takeProfitPrice) external nonpayable
Parameters
| Name | Type | Description |
|---|---|---|
| predictionIDs | uint256[] | undefined |
| stopLossPrice | uint256[] | undefined |
| takeProfitPrice | uint256[] | undefined |
changePredictionsLifetime
function changePredictionsLifetime(uint256 newPredictionsLifetime) external nonpayable
Parameters
| Name | Type | Description |
|---|---|---|
| newPredictionsLifetime | uint256 | undefined |
changePricesAddress
function changePricesAddress(address newPricesAddress) external nonpayable
Parameters
| Name | Type | Description |
|---|---|---|
| newPricesAddress | address | undefined |
closePrediction
function closePrediction(uint256 predictionID, uint256 expectedPrice, bytes32 salt, bool isDirectionUp) external nonpayable
Parameters
| Name | Type | Description |
|---|---|---|
| predictionID | uint256 | undefined |
| expectedPrice | uint256 | undefined |
| salt | bytes32 | undefined |
| isDirectionUp | bool | undefined |
closePredictionByPriceIndex
function closePredictionByPriceIndex(uint256 predictionID, bytes32 salt, bool isDirectionUp, uint256 priceIndex) external nonpayable
Parameters
| Name | Type | Description |
|---|---|---|
| predictionID | uint256 | undefined |
| salt | bytes32 | undefined |
| isDirectionUp | bool | undefined |
| priceIndex | uint256 | undefined |
closePredictions
function closePredictions(uint256[] predictionIDs, uint256[] expectedPrices, bytes32[] salt, bool[] isDirectionUp) external nonpayable