Class ForceLogoutProvider.LogoutTimeCalculator

java.lang.Object
io.deephaven.enterprise.webclientdata2.ForceLogoutProvider.LogoutTimeCalculator
Enclosing class:
ForceLogoutProvider

public static class ForceLogoutProvider.LogoutTimeCalculator extends Object
Calculator class for computing and memoizing logout times.
  • Constructor Details

    • LogoutTimeCalculator

      public LogoutTimeCalculator()
  • Method Details

    • calculateLogoutTime

      public Instant calculateLogoutTime(@NotNull @NotNull String id, @NotNull @NotNull Instant updateTime, @NotNull @NotNull String schedule, @Nullable @Nullable String scheduleDate, @NotNull @NotNull String time, @NotNull @NotNull String timezone, byte days, @NotNull @NotNull Instant currentTime, boolean returnNextOccurrence)
      Calculate logout time for a schedule with memoization.
      Parameters:
      id - the schedule id
      updateTime - the time the schedule was created/modified
      schedule - one of "Once", "Daily", "Weekly"
      scheduleDate - the date for "Once" scheduled logouts, null for others
      time - the time of day for the logout
      timezone - the timezone for the scheduled time
      days - for "Weekly", a bitfield where bit 0 = Sunday, bit 1 = Monday, etc.
      currentTime - the current time
      returnNextOccurrence - if true, returns next occurrence (for display); if false, returns current occurrence (for triggering)
      Returns:
      the logout Instant, or null if no valid logout time can be computed