java.lang.Object
com.azure.resourcemanager.containerservice.models.Schedule
All Implemented Interfaces:
com.azure.json.JsonSerializable<Schedule>

public final class Schedule extends Object implements com.azure.json.JsonSerializable<Schedule>
One and only one of the schedule types should be specified. Choose either 'daily', 'weekly', 'absoluteMonthly' or 'relativeMonthly' for your maintenance schedule.
  • Constructor Summary

    Constructors
    Constructor
    Description
    Creates an instance of Schedule class.
  • Method Summary

    Modifier and Type
    Method
    Description
    Get the absoluteMonthly property: For schedules like: 'recur every month on the 15th' or 'recur every 3 months on the 20th'.
    Get the daily property: For schedules like: 'recur every day' or 'recur every 3 days'.
    static Schedule
    fromJson(com.azure.json.JsonReader jsonReader)
    Reads an instance of Schedule from the JsonReader.
    Get the relativeMonthly property: For schedules like: 'recur every month on the first Monday' or 'recur every 3 months on last Friday'.
    com.azure.json.JsonWriter
    toJson(com.azure.json.JsonWriter jsonWriter)
    void
    Validates the instance.
    Get the weekly property: For schedules like: 'recur every Monday' or 'recur every 3 weeks on Wednesday'.
    Set the absoluteMonthly property: For schedules like: 'recur every month on the 15th' or 'recur every 3 months on the 20th'.
    Set the daily property: For schedules like: 'recur every day' or 'recur every 3 days'.
    Set the relativeMonthly property: For schedules like: 'recur every month on the first Monday' or 'recur every 3 months on last Friday'.
    Set the weekly property: For schedules like: 'recur every Monday' or 'recur every 3 weeks on Wednesday'.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface com.azure.json.JsonSerializable

    toJson, toJson, toJsonBytes, toJsonString
  • Constructor Details

    • Schedule

      public Schedule()
      Creates an instance of Schedule class.
  • Method Details

    • daily

      public DailySchedule daily()
      Get the daily property: For schedules like: 'recur every day' or 'recur every 3 days'.
      Returns:
      the daily value.
    • withDaily

      public Schedule withDaily(DailySchedule daily)
      Set the daily property: For schedules like: 'recur every day' or 'recur every 3 days'.
      Parameters:
      daily - the daily value to set.
      Returns:
      the Schedule object itself.
    • weekly

      public WeeklySchedule weekly()
      Get the weekly property: For schedules like: 'recur every Monday' or 'recur every 3 weeks on Wednesday'.
      Returns:
      the weekly value.
    • withWeekly

      public Schedule withWeekly(WeeklySchedule weekly)
      Set the weekly property: For schedules like: 'recur every Monday' or 'recur every 3 weeks on Wednesday'.
      Parameters:
      weekly - the weekly value to set.
      Returns:
      the Schedule object itself.
    • absoluteMonthly

      public AbsoluteMonthlySchedule absoluteMonthly()
      Get the absoluteMonthly property: For schedules like: 'recur every month on the 15th' or 'recur every 3 months on the 20th'.
      Returns:
      the absoluteMonthly value.
    • withAbsoluteMonthly

      public Schedule withAbsoluteMonthly(AbsoluteMonthlySchedule absoluteMonthly)
      Set the absoluteMonthly property: For schedules like: 'recur every month on the 15th' or 'recur every 3 months on the 20th'.
      Parameters:
      absoluteMonthly - the absoluteMonthly value to set.
      Returns:
      the Schedule object itself.
    • relativeMonthly

      public RelativeMonthlySchedule relativeMonthly()
      Get the relativeMonthly property: For schedules like: 'recur every month on the first Monday' or 'recur every 3 months on last Friday'.
      Returns:
      the relativeMonthly value.
    • withRelativeMonthly

      public Schedule withRelativeMonthly(RelativeMonthlySchedule relativeMonthly)
      Set the relativeMonthly property: For schedules like: 'recur every month on the first Monday' or 'recur every 3 months on last Friday'.
      Parameters:
      relativeMonthly - the relativeMonthly value to set.
      Returns:
      the Schedule object itself.
    • validate

      public void validate()
      Validates the instance.
      Throws:
      IllegalArgumentException - thrown if the instance is not valid.
    • toJson

      public com.azure.json.JsonWriter toJson(com.azure.json.JsonWriter jsonWriter) throws IOException
      Specified by:
      toJson in interface com.azure.json.JsonSerializable<Schedule>
      Throws:
      IOException
    • fromJson

      public static Schedule fromJson(com.azure.json.JsonReader jsonReader) throws IOException
      Reads an instance of Schedule from the JsonReader.
      Parameters:
      jsonReader - The JsonReader being read.
      Returns:
      An instance of Schedule if the JsonReader was pointing to an instance of it, or null if it was pointing to JSON null.
      Throws:
      IOException - If an error occurs while reading the Schedule.