Class MaintenanceWindowForPatch
java.lang.Object
com.azure.resourcemanager.postgresqlflexibleserver.models.MaintenanceWindowForPatch
- All Implemented Interfaces:
com.azure.json.JsonSerializable<MaintenanceWindowForPatch>
public final class MaintenanceWindowForPatch
extends Object
implements com.azure.json.JsonSerializable<MaintenanceWindowForPatch>
Maintenance window properties of a server.
-
Constructor Summary
ConstructorsConstructorDescriptionCreates an instance of MaintenanceWindowForPatch class. -
Method Summary
Modifier and TypeMethodDescriptionGet the customWindow property: Indicates whether custom window is enabled or disabled.Get the dayOfWeek property: Day of the week to be used for maintenance window.static MaintenanceWindowForPatchfromJson(com.azure.json.JsonReader jsonReader) Reads an instance of MaintenanceWindowForPatch from the JsonReader.Get the startHour property: Start hour to be used for maintenance window.Get the startMinute property: Start minute to be used for maintenance window.com.azure.json.JsonWritertoJson(com.azure.json.JsonWriter jsonWriter) voidvalidate()Validates the instance.withCustomWindow(String customWindow) Set the customWindow property: Indicates whether custom window is enabled or disabled.withDayOfWeek(Integer dayOfWeek) Set the dayOfWeek property: Day of the week to be used for maintenance window.withStartHour(Integer startHour) Set the startHour property: Start hour to be used for maintenance window.withStartMinute(Integer startMinute) Set the startMinute property: Start minute to be used for maintenance window.Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.azure.json.JsonSerializable
toJson, toJson, toJsonBytes, toJsonString
-
Constructor Details
-
MaintenanceWindowForPatch
public MaintenanceWindowForPatch()Creates an instance of MaintenanceWindowForPatch class.
-
-
Method Details
-
customWindow
Get the customWindow property: Indicates whether custom window is enabled or disabled.- Returns:
- the customWindow value.
-
withCustomWindow
Set the customWindow property: Indicates whether custom window is enabled or disabled.- Parameters:
customWindow- the customWindow value to set.- Returns:
- the MaintenanceWindowForPatch object itself.
-
startHour
Get the startHour property: Start hour to be used for maintenance window.- Returns:
- the startHour value.
-
withStartHour
Set the startHour property: Start hour to be used for maintenance window.- Parameters:
startHour- the startHour value to set.- Returns:
- the MaintenanceWindowForPatch object itself.
-
startMinute
Get the startMinute property: Start minute to be used for maintenance window.- Returns:
- the startMinute value.
-
withStartMinute
Set the startMinute property: Start minute to be used for maintenance window.- Parameters:
startMinute- the startMinute value to set.- Returns:
- the MaintenanceWindowForPatch object itself.
-
dayOfWeek
Get the dayOfWeek property: Day of the week to be used for maintenance window.- Returns:
- the dayOfWeek value.
-
withDayOfWeek
Set the dayOfWeek property: Day of the week to be used for maintenance window.- Parameters:
dayOfWeek- the dayOfWeek value to set.- Returns:
- the MaintenanceWindowForPatch object itself.
-
validate
public void validate()Validates the instance.- Throws:
IllegalArgumentException- thrown if the instance is not valid.
-
toJson
- Specified by:
toJsonin interfacecom.azure.json.JsonSerializable<MaintenanceWindowForPatch>- Throws:
IOException
-
fromJson
public static MaintenanceWindowForPatch fromJson(com.azure.json.JsonReader jsonReader) throws IOException Reads an instance of MaintenanceWindowForPatch from the JsonReader.- Parameters:
jsonReader- The JsonReader being read.- Returns:
- An instance of MaintenanceWindowForPatch 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 MaintenanceWindowForPatch.
-