All Implemented Interfaces:
Serializable, Comparable<DateFormat>, Constable

public enum DateFormat extends Enum<DateFormat>
Values based on reference doc - The patterns are taken from this documentation and slightly adapted so that a Java DateTimeFormatter produces the same values as the Elasticsearch formatter.
Jakub Vavrik, Tim te Beek, Peter-Josef Meisch, Sascha Woo
  • Enum Constant Details

    • none

      @Deprecated public static final DateFormat none
      since 4.2, will be removed in a future version. Use format = {} to disable built-in date formats in the @Field annotation.
    • custom

      @Deprecated public static final DateFormat custom
      since 4.2, will be removed in a future version.It is no longer required for using a custom date format pattern. If you want to use only a custom date format pattern, you must set the format property to empty {}.
    • basic_date

      public static final DateFormat basic_date
    • basic_date_time

      public static final DateFormat basic_date_time
    • basic_date_time_no_millis

      public static final DateFormat basic_date_time_no_millis
    • basic_ordinal_date

      public static final DateFormat basic_ordinal_date
    • basic_ordinal_date_time

      public static final DateFormat basic_ordinal_date_time
    • basic_ordinal_date_time_no_millis

      public static final DateFormat basic_ordinal_date_time_no_millis
    • basic_time

      public static final DateFormat basic_time
    • basic_time_no_millis

      public static final DateFormat basic_time_no_millis
    • basic_t_time

      public static final DateFormat basic_t_time
    • basic_t_time_no_millis

      public static final DateFormat basic_t_time_no_millis
    • basic_week_date

      public static final DateFormat basic_week_date
    • basic_week_date_time

      public static final DateFormat basic_week_date_time
    • basic_week_date_time_no_millis

      public static final DateFormat basic_week_date_time_no_millis
    • date

      public static final DateFormat date
    • date_hour

      public static final DateFormat date_hour
    • date_hour_minute

      public static final DateFormat date_hour_minute
    • date_hour_minute_second

      public static final DateFormat date_hour_minute_second
    • date_hour_minute_second_fraction

      public static final DateFormat date_hour_minute_second_fraction
    • date_hour_minute_second_millis

      public static final DateFormat date_hour_minute_second_millis
    • date_optional_time

      public static final DateFormat date_optional_time
    • date_time

      public static final DateFormat date_time
    • date_time_no_millis

      public static final DateFormat date_time_no_millis
    • epoch_millis

      public static final DateFormat epoch_millis
    • epoch_second

      public static final DateFormat epoch_second
    • hour

      public static final DateFormat hour
    • hour_minute

      public static final DateFormat hour_minute
    • hour_minute_second

      public static final DateFormat hour_minute_second
    • hour_minute_second_fraction

      public static final DateFormat hour_minute_second_fraction
    • hour_minute_second_millis

      public static final DateFormat hour_minute_second_millis
    • ordinal_date

      public static final DateFormat ordinal_date
    • ordinal_date_time

      public static final DateFormat ordinal_date_time
    • ordinal_date_time_no_millis

      public static final DateFormat ordinal_date_time_no_millis
    • time

      public static final DateFormat time
    • time_no_millis

      public static final DateFormat time_no_millis
    • t_time

      public static final DateFormat t_time
    • t_time_no_millis

      public static final DateFormat t_time_no_millis
    • week_date

      public static final DateFormat week_date
    • week_date_time

      public static final DateFormat week_date_time
    • week_date_time_no_millis

      public static final DateFormat week_date_time_no_millis
    • weekyear

      public static final DateFormat weekyear
    • weekyear_week

      public static final DateFormat weekyear_week
    • weekyear_week_day

      public static final DateFormat weekyear_week_day
    • year

      public static final DateFormat year
    • year_month

      public static final DateFormat year_month
    • year_month_day

      public static final DateFormat year_month_day
  • Method Details

    • values

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

      public static DateFormat 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.)
      name - the name of the enum constant to be returned.
      the enum constant with the specified name
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null
    • getPattern

      public String getPattern()