java.lang.Object
co.elastic.clients.elasticsearch.watcher.Schedule
All Implemented Interfaces:
TriggerVariant, JsonpSerializable, TaggedUnion<Schedule.Kind,Object>

See Also:
  • Field Details

  • Constructor Details

  • Method Details

    • _triggerKind

      public Trigger.Kind _triggerKind()
      Trigger variant kind.
      Specified by:
      _triggerKind in interface TriggerVariant
    • _kind

      public final Schedule.Kind _kind()
      Description copied from interface: TaggedUnion
      Get the of the kind of variant held by this object.
      Specified by:
      _kind in interface TaggedUnion<Schedule.Kind,Object>
      Returns:
      the variant kind
    • _get

      public final Object _get()
      Specified by:
      _get in interface TaggedUnion<Schedule.Kind,Object>
    • of

    • isTimezone

      public boolean isTimezone()
      Is this variant instance of kind timezone?
    • timezone

      public String timezone()
      Get the timezone variant value.
      Throws:
      IllegalStateException - if the current variant is not of the timezone kind.
    • isCron

      public boolean isCron()
      Is this variant instance of kind cron?
    • cron

      public String cron()
      Get the cron variant value.
      Throws:
      IllegalStateException - if the current variant is not of the cron kind.
    • isDaily

      public boolean isDaily()
      Is this variant instance of kind daily?
    • daily

      public DailySchedule daily()
      Get the daily variant value.
      Throws:
      IllegalStateException - if the current variant is not of the daily kind.
    • isHourly

      public boolean isHourly()
      Is this variant instance of kind hourly?
    • hourly

      public HourlySchedule hourly()
      Get the hourly variant value.
      Throws:
      IllegalStateException - if the current variant is not of the hourly kind.
    • isInterval

      public boolean isInterval()
      Is this variant instance of kind interval?
    • interval

      public Time interval()
      Get the interval variant value.
      Throws:
      IllegalStateException - if the current variant is not of the interval kind.
    • isMonthly

      public boolean isMonthly()
      Is this variant instance of kind monthly?
    • monthly

      public List<TimeOfMonth> monthly()
      Get the monthly variant value.
      Throws:
      IllegalStateException - if the current variant is not of the monthly kind.
    • isWeekly

      public boolean isWeekly()
      Is this variant instance of kind weekly?
    • weekly

      public List<TimeOfWeek> weekly()
      Get the weekly variant value.
      Throws:
      IllegalStateException - if the current variant is not of the weekly kind.
    • isYearly

      public boolean isYearly()
      Is this variant instance of kind yearly?
    • yearly

      public List<TimeOfYear> yearly()
      Get the yearly variant value.
      Throws:
      IllegalStateException - if the current variant is not of the yearly kind.
    • serialize

      public void serialize(jakarta.json.stream.JsonGenerator generator, JsonpMapper mapper)
      Specified by:
      serialize in interface JsonpSerializable
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • setupScheduleDeserializer

      protected static void setupScheduleDeserializer(ObjectDeserializer<Schedule.Builder> op)