Skip to content

Commit

Permalink
rename IPool.expire to release, track open claims/payouts in Policy
Browse files Browse the repository at this point in the history
  • Loading branch information
matthiaszimmermann committed Jul 17, 2022
1 parent 4d8f578 commit 0bc9b44
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
4 changes: 3 additions & 1 deletion contracts/modules/IPolicy.sol
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ interface IPolicy {

enum ApplicationState {Applied, Revoked, Underwritten, Declined}

enum PolicyState {Active, Expired}
enum PolicyState {Active, Expired, Closed}

enum ClaimState {Applied, Confirmed, Declined}

Expand Down Expand Up @@ -103,7 +103,9 @@ interface IPolicy {
struct Policy {
PolicyState state;
uint256 claimsCount;
uint256 openClaimsCount;
uint256 payoutsCount;
uint256 openPayoutsCount;
uint256 createdAt;
uint256 updatedAt;
}
Expand Down
3 changes: 2 additions & 1 deletion contracts/modules/IPool.sol
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,9 @@ interface IPool {
event LogRiskpoolCollateralizationSucceeded(uint256 riskpoolId, bytes32 processId, uint256 amount);

function setRiskpoolForProduct(uint256 productId, uint256 riskpoolId) external;

function underwrite(bytes32 processId) external returns(bool success);
function expire(bytes32 processId) external;
function release(bytes32 processId) external;

function increaseBalance(bytes32 processId, uint256 amount) external;
function decreaseBalance(bytes32 processId, uint256 amount) external;
Expand Down

0 comments on commit 0bc9b44

Please sign in to comment.