namespace TarninaHub.Domain.Rules; public static class ApplicationWindow { public const string Open = "open"; /// /// Applications are only allowed while the call is open and the current /// moment is within [opensAt, closesAt]. /// public static bool IsOpen(string status, DateTimeOffset opensAt, DateTimeOffset closesAt, DateTimeOffset now) => string.Equals(status, Open, StringComparison.Ordinal) && now >= opensAt && now <= closesAt; }