code: @Override
    public Date getFireTimeAfter (@Nullable final Date aAfterTime)
    {
      if (m_bComplete)
        return null;
  
      if ((m_nTimesTriggered > m_nRepeatCount) && (m_nRepeatCount != REPEAT_INDEFINITELY))
        return null;
  
      Date afterTime = aAfterTime;
      if (afterTime == null)
        afterTime = new Date ();
  
      if (m_nRepeatCount == 0 && afterTime.compareTo (getStartTime ()) >= 0)
        return null;
  
      final long startMillis = getStartTime ().getTime ();
      final long afterMillis = afterTime.getTime ();
      final long endMillis = (getEndTime () == null) ? Long.MAX_VALUE : getEndTime ().getTime ();
  
      if (endMillis <= afterMillis)
        return null;
  
      if (afterMillis < startMillis)
        return new Date (startMillis);
  
      final long numberOfTimesExecuted = ((afterMillis - startMillis) / m_nRepeatInterval) + 1;
  
      if ((numberOfTimesExecuted > m_nRepeatCount) && (m_nRepeatCount != REPEAT_INDEFINITELY))
        return null;
  
      final Date time = new Date (startMillis + (numberOfTimesExecuted * m_nRepeatInterval));
      if (endMillis <= time.getTime ())
        return null;
      return time;
    }
docs: <p>
  Returns the next time at which the <code>SimpleTrigger</code> will fire,
  after the given time. If the trigger will not fire after the given time,
  <code>null</code> will be returned.
  </p>
  
  @param aAfterTime
  After time. May be <code>null</code>