Enum Class RecurrenceRule.RfcMode

java.lang.Object
java.lang.Enum<RecurrenceRule.RfcMode>
org.dmfs.rfc5545.recur.RecurrenceRule.RfcMode
All Implemented Interfaces:
Serializable, Comparable<RecurrenceRule.RfcMode>, Constable
Enclosing class:
RecurrenceRule

public static enum RecurrenceRule.RfcMode extends Enum<RecurrenceRule.RfcMode>
Enumeration of supported rule versions.
  • Enum Constant Details

    • RFC2445_STRICT

      public static final RecurrenceRule.RfcMode RFC2445_STRICT
      Parses recurrence rules according to RFC 2445. Every error will cause an exception to be thrown.
    • RFC2445_LAX

      public static final RecurrenceRule.RfcMode RFC2445_LAX
      Parses recurrence rules according to RFC 2445 in a more tolerant way. The parser will just skip invalid parts in the rule and won't complain as long as the result is a valid rule.

      This mode also accepts rules that comply with RFC 5545.

      Note: Using this mode rules are evaluated differently than with RFC5545_LAX. RFC5545_LAX will just drop all invalid parts and evaluate the rule according to RFC 5545. This mode will evaluate all rules.

      Also this mode will output rules that comply with RFC 2445.

    • RFC5545_STRICT

      public static final RecurrenceRule.RfcMode RFC5545_STRICT
      Parses recurrence rules according to RFC 5545. Every error will cause an exception to be thrown.
    • RFC5545_LAX

      public static final RecurrenceRule.RfcMode RFC5545_LAX
      Parses recurrence rules according to RFC 5545 in a more tolerant way. The parser will just skip invalid parts in the rule and won't complain as long as the result is a valid rule.

      This mode also accepts rules that comply with RFC 2445 but not with RFC 5545.

      Note: Using this mode rules are evaluated differently than with RFC2445_LAX. This mode will just drop all invalid parts and evaluate the rule according to RFC 5545. RFC2445_LAX will evaluate all rules.

      Also this mode will output rules that comply with RFC 5545.

  • Method Details

    • values

      public static RecurrenceRule.RfcMode[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static RecurrenceRule.RfcMode valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null