code: @Override
      @Trivial
      protected Date getNextTimeout(int operation) {
          final boolean isTraceOn = TraceComponent.isAnyTracingEnabled();
          if (isTraceOn && tc.isEntryEnabled())
              Tr.entry(tc, "getNextTimeout: " + operation);
  
          // Determine if the calling bean is in a state that allows timer service
          // method access - throws IllegalStateException if not allowed.
          checkTimerAccess();
  
          Date nextTimeout;
          if (j2eeName == null || isAnyCachingAllowed()) {
              TaskStatus<?> taskStatus = getTimerStatus(operation);
              nextTimeout = taskStatus.getNextExecutionTime();
          } else {
              try {
                  nextTimeout = persistentTimerRuntime.getNextExecutionTime(taskId);
              } catch (Throwable ex) {
                  throw newTimerServiceException(ex);
              }
              if (nextTimeout == null) {
                  throw newNoSuchObjectLocalException();
              }
          }
  
          if (isTimeoutCallback) {
              PersistentTimerTaskHandler taskHandler = getTimerTaskHandler(operation);
              Date afterCurrentTimeout = taskHandler.getNextTimeout(nextTimeout, null);
  
              if (afterCurrentTimeout != null) {
                  nextTimeout = afterCurrentTimeout;
              } else {
                  // The calendar-based timer associated with a timeout callback must
                  // throw NoMoreTimeoutsException while within the timeout callback.
                  if (taskHandler.getParsedSchedule() != null) {
                      NoMoreTimeoutsException nmte = new NoMoreTimeoutsException(toString());
                      if (isTraceOn && tc.isEntryEnabled())
                          Tr.exit(tc, "getNextTimeout: " + nmte);
                      throw nmte;
                  }
                  // Otherwise, it is a single action timer, return the current timeout
              }
          }
  
          if (isTraceOn && tc.isEntryEnabled())
              Tr.exit(tc, "getNextTimeout: " + nextTimeout);
  
          return nextTimeout;
      }
docs: --------------------------------------------------------------------------