Skip to content

Latest commit

 

History

History
268 lines (241 loc) · 8.44 KB

IUnstakable.md

File metadata and controls

268 lines (241 loc) · 8.44 KB

IUnstakable.sol

View Source: contracts/interfaces/IUnstakable.sol

↘ Derived Contracts: IResolution, Unstakable

IUnstakable

Events

event Unstaken(bytes32 indexed coverKey, bytes32 indexed productKey, address indexed caller, uint256  originalStake, uint256  reward);
event ReporterRewardDistributed(bytes32 indexed coverKey, bytes32 indexed productKey, address  caller, address indexed reporter, uint256  originalReward, uint256  reporterReward);
event GovernanceBurned(bytes32 indexed coverKey, bytes32 indexed productKey, address  caller, address indexed burner, uint256  originalReward, uint256  burnedAmount);

Functions

unstake

function unstake(bytes32 coverKey, bytes32 productKey, uint256 incidentDate) external nonpayable

Arguments

Name Type Description
coverKey bytes32
productKey bytes32
incidentDate uint256
Source Code
function unstake(
    bytes32 coverKey,
    bytes32 productKey,
    uint256 incidentDate
  ) external;

unstakeWithClaim

function unstakeWithClaim(bytes32 coverKey, bytes32 productKey, uint256 incidentDate) external nonpayable

Arguments

Name Type Description
coverKey bytes32
productKey bytes32
incidentDate uint256
Source Code
function unstakeWithClaim(
    bytes32 coverKey,
    bytes32 productKey,
    uint256 incidentDate
  ) external;

getUnstakeInfoFor

function getUnstakeInfoFor(address account, bytes32 coverKey, bytes32 productKey, uint256 incidentDate) external view
returns(totalStakeInWinningCamp uint256, totalStakeInLosingCamp uint256, myStakeInWinningCamp uint256, toBurn uint256, toReporter uint256, myReward uint256, unstaken uint256)

Arguments

Name Type Description
account address
coverKey bytes32
productKey bytes32
incidentDate uint256
Source Code
function getUnstakeInfoFor(
    address account,
    bytes32 coverKey,
    bytes32 productKey,
    uint256 incidentDate
  )
    external
    view
    returns (
      uint256 totalStakeInWinningCamp,
      uint256 totalStakeInLosingCamp,
      uint256 myStakeInWinningCamp,
      uint256 toBurn,
      uint256 toReporter,
      uint256 myReward,
      uint256 unstaken
    );

Contracts