Class AdvancedScheduleMonthlyOccurrence

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

public final class AdvancedScheduleMonthlyOccurrence extends Object implements com.azure.json.JsonSerializable<AdvancedScheduleMonthlyOccurrence>
The properties of the create advanced schedule monthly occurrence.
  • Constructor Details

    • AdvancedScheduleMonthlyOccurrence

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

    • occurrence

      public Integer occurrence()
      Get the occurrence property: Occurrence of the week within the month. Must be between 1 and 5.
      Returns:
      the occurrence value.
    • withOccurrence

      public AdvancedScheduleMonthlyOccurrence withOccurrence(Integer occurrence)
      Set the occurrence property: Occurrence of the week within the month. Must be between 1 and 5.
      Parameters:
      occurrence - the occurrence value to set.
      Returns:
      the AdvancedScheduleMonthlyOccurrence object itself.
    • day

      public ScheduleDay day()
      Get the day property: Day of the occurrence. Must be one of monday, tuesday, wednesday, thursday, friday, saturday, sunday.
      Returns:
      the day value.
    • withDay

      Set the day property: Day of the occurrence. Must be one of monday, tuesday, wednesday, thursday, friday, saturday, sunday.
      Parameters:
      day - the day value to set.
      Returns:
      the AdvancedScheduleMonthlyOccurrence 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<AdvancedScheduleMonthlyOccurrence>
      Throws:
      IOException
    • fromJson

      public static AdvancedScheduleMonthlyOccurrence fromJson(com.azure.json.JsonReader jsonReader) throws IOException
      Reads an instance of AdvancedScheduleMonthlyOccurrence from the JsonReader.
      Parameters:
      jsonReader - The JsonReader being read.
      Returns:
      An instance of AdvancedScheduleMonthlyOccurrence 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 AdvancedScheduleMonthlyOccurrence.