2023-08-04 19:17:23 +02:00
|
|
|
pragma solidity >=0.6.12;
|
|
|
|
|
|
|
|
// Author: Louis Holbrook <dev@holbrook.no> 0826EDA1702D1E87C6E2875121D2E7BB88C2A746
|
|
|
|
// SPDX-License-Identifier: AGPL-3.0-or-later
|
|
|
|
// File-version: 1
|
|
|
|
|
|
|
|
interface IThrottle {
|
|
|
|
// Returns true if the given address is authorized to make use of the resource at the current moment.
|
|
|
|
// Implements ACL
|
|
|
|
function have(address _address) external view returns(bool);
|
|
|
|
|
2023-10-29 11:52:11 +01:00
|
|
|
// Returns the timestamp when the resource may next be used by the given address.
|
|
|
|
// A return value of 0 or a timestamp before the current timestamp indicates that the resource may used momentarily.
|
|
|
|
// A return value of max uint265 can be used to indicate that the resource may never be used again by the address.
|
|
|
|
function next(address _address) external returns(bool);
|
|
|
|
|
2023-08-04 19:17:23 +02:00
|
|
|
// Must be called when the resource is being used.
|
|
|
|
function poke(address _address) external returns(bool);
|
|
|
|
}
|