java.lang.Object
java.lang.Enum<DateTimeMode>
de.espirit.firstspirit.access.store.templatestore.gom.DateTimeMode
All Implemented Interfaces:
Serializable, Comparable<DateTimeMode>, Constable

public enum DateTimeMode extends Enum<DateTimeMode>
Switch for setting the date mode of a form.
Since:
4.2.200
  • Enum Constant Details

    • DATETIME

      public static final DateTimeMode DATETIME
      Use both date and time
      Since:
      4.2.200
    • DATE

      public static final DateTimeMode DATE
      Use date only
      Since:
      4.2.200
    • TIME

      public static final DateTimeMode TIME
      Use time only
      Since:
      4.2.200
  • Method Details

    • values

      public static DateTimeMode[] 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 DateTimeMode 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
    • toApplicationTime

      public abstract long toApplicationTime(long milliseconds)
      Convert the given time to mode-dependent application time.
      Parameters:
      milliseconds - The time to be converted.
      Returns:
      The mode-dependent time.
      Since:
      4.2.203
    • toPersistencyTime

      public abstract long toPersistencyTime(long milliseconds)
      Convert the given time to mode-dependent persistency time.
      Parameters:
      milliseconds - The time to be converted.
      Returns:
      The mode-dependent time.
      Since:
      4.2.203
    • adjustTime

      public abstract long adjustTime(long milliseconds)
      Adjust a time to its mode-dependent time representation.
      Parameters:
      milliseconds - The time to be converted.
      Returns:
      The mode-dependent time.
      Since:
      4.2.203
    • getDefaultFormat

      public abstract DateFormat getDefaultFormat(Locale locale)
      Get the default, mode-dependent format for the given locale.
      Parameters:
      locale - The locale to get the format for.
      Returns:
      The default format.
      Since:
      4.2.200
    • adjustDate

      public Date adjustDate(Date date)
      Adjust the date according to the date time mode.
      Parameters:
      date - The date to be adjusted.
      Returns:
      A new date instance from the adjusted time.
      Since:
      4.2.205
    • isTimezoneIndependent

      public boolean isTimezoneIndependent()
      Indicates that only numerical persistency works for this mode.
      Returns:
      true, iff only numercial persistency is allowed.
      Since:
      4.2.205