Class CronMinutesEntry

java.lang.Object
com.atlassian.jira.web.component.cron.parser.CronMinutesEntry

public class CronMinutesEntry extends Object
Represents the minutes part of a cron string. This class is responsible for parsing and validating this entry. The isValid() method refers only to what is supported by the cron editor for the minutes entry.

Valid minutes include only those that are either: a multiple of 5 between 0 and 55 inclusive; or "0/15" or "0/30" meaning every 15 minutes or every 30 minutes.

  • Constructor Details

    • CronMinutesEntry

      public CronMinutesEntry(String cronEntry)
      Parses the given minute field into this CronMinutesEntry state.
      Parameters:
      cronEntry - the minute field of a cron string.
  • Method Details

    • isValid

      public boolean isValid()
      Indicates that the minute field is able to be handled by the editor, concerns both the minute value and the optional increment value.
      Returns:
      true only if the minute field is valid.
    • getRunOnce

      public int getRunOnce()
      The minute value for a single fire time.
      Returns:
      the minute value.
    • getIncrement

      public int getIncrement()
    • hasIncrement

      public boolean hasIncrement()