cic-contracts/solidity/Expire.sol

24 lines
654 B
Solidity

pragma solidity >=0.6.12;
// Author: Louis Holbrook <dev@holbrook.no> 0826EDA1702D1E87C6E2875121D2E7BB88C2A746
// SPDX-License-Identifier: AGPL-3.0-or-later
// File-version: 3
interface IExpire {
// Contract has expired.
event Expired(uint256 _timestamp);
// Expiry time has changed.
event ExpiryChange(uint256 indexed _oldTimestamp, uint256 _newTimestamp);
// The current expiration timestamp.
function expires() external returns (uint256);
// Check expiry and apply expiration if expired.
// Return values must be:
// 0: not yet expired.
// 1: already expired.
// >1: expiry executed.
function applyExpiry() external returns(uint8);
}