ITrackablePromise.cs 614 B

12345678910111213141516171819
  1. // Copyright (c) 2025 TerraByte Inc.
  2. //
  3. // A non-generic interface that allows the PromiseManager to track and
  4. // tick promises without needing to know their specific result type.
  5. namespace Terra.Arbitrator.Promises
  6. {
  7. /// <summary>
  8. /// Represents a promise that can be ticked by the PromiseManager.
  9. /// </summary>
  10. public interface ITrackablePromise
  11. {
  12. /// <summary>
  13. /// Executes pending callbacks if the promise is settled.
  14. /// </summary>
  15. /// <returns>True if the promise is settled (resolved or rejected), otherwise false.</returns>
  16. bool Tick();
  17. }
  18. }