Class DateIndexNameProcessor.Builder

All Implemented Interfaces:
WithJson<DateIndexNameProcessor.Builder>, ObjectBuilder<DateIndexNameProcessor>
Enclosing class:
DateIndexNameProcessor

public static class DateIndexNameProcessor.Builder extends ProcessorBase.AbstractBuilder<DateIndexNameProcessor.Builder> implements ObjectBuilder<DateIndexNameProcessor>
  • Constructor Details

    • Builder

      public Builder()
  • Method Details

    • dateFormats

      public final DateIndexNameProcessor.Builder dateFormats(List<String> list)
      Required - An array of the expected date formats for parsing dates / timestamps in the document being preprocessed. Can be a java time pattern or one of the following formats: ISO8601, UNIX, UNIX_MS, or TAI64N.

      API name: date_formats

      Adds all elements of list to dateFormats.

    • dateFormats

      public final DateIndexNameProcessor.Builder dateFormats(String value, String... values)
      Required - An array of the expected date formats for parsing dates / timestamps in the document being preprocessed. Can be a java time pattern or one of the following formats: ISO8601, UNIX, UNIX_MS, or TAI64N.

      API name: date_formats

      Adds one or more values to dateFormats.

    • dateRounding

      public final DateIndexNameProcessor.Builder dateRounding(String value)
      Required - How to round the date when formatting the date into the index name. Valid values are: y (year), M (month), w (week), d (day), h (hour), m (minute) and s (second). Supports template snippets.

      API name: date_rounding

    • field

      public final DateIndexNameProcessor.Builder field(String value)
      Required - The field to get the date or timestamp from.

      API name: field

    • indexNameFormat

      public final DateIndexNameProcessor.Builder indexNameFormat(@Nullable String value)
      The format to be used when printing the parsed date into the index name. A valid java time pattern is expected here. Supports template snippets.

      API name: index_name_format

    • indexNamePrefix

      public final DateIndexNameProcessor.Builder indexNamePrefix(@Nullable String value)
      A prefix of the index name to be prepended before the printed date. Supports template snippets.

      API name: index_name_prefix

    • locale

      public final DateIndexNameProcessor.Builder locale(@Nullable String value)
      The locale to use when parsing the date from the document being preprocessed, relevant when parsing month names or week days.

      API name: locale

    • timezone

      public final DateIndexNameProcessor.Builder timezone(@Nullable String value)
      The timezone to use when parsing the date and when date math index supports resolves expressions into concrete index names.

      API name: timezone

    • self

      Specified by:
      self in class ProcessorBase.AbstractBuilder<DateIndexNameProcessor.Builder>
    • build

      public DateIndexNameProcessor build()
      Specified by:
      build in interface ObjectBuilder<DateIndexNameProcessor>
      Throws:
      NullPointerException - if some of the required fields are null.