Class ScheduleCreationParameter
java.lang.Object
com.azure.resourcemanager.devtestlabs.models.ScheduleCreationParameter
- All Implemented Interfaces:
com.azure.json.JsonSerializable<ScheduleCreationParameter>
public final class ScheduleCreationParameter
extends Object
implements com.azure.json.JsonSerializable<ScheduleCreationParameter>
Properties for creating a schedule.
-
Constructor Summary
ConstructorsConstructorDescriptionCreates an instance of ScheduleCreationParameter class. -
Method Summary
Modifier and TypeMethodDescriptionGet the dailyRecurrence property: If the schedule will occur once each day of the week, specify the daily recurrence.static ScheduleCreationParameter
fromJson
(com.azure.json.JsonReader jsonReader) Reads an instance of ScheduleCreationParameter from the JsonReader.Get the hourlyRecurrence property: If the schedule will occur multiple times a day, specify the hourly recurrence.location()
Get the location property: The location of the new virtual machine or environment.name()
Get the name property: The name of the virtual machine or environment.Get the notificationSettings property: Notification settings.status()
Get the status property: The status of the schedule (i.e.tags()
Get the tags property: The tags of the resource.Get the targetResourceId property: The resource ID to which the schedule belongs.taskType()
Get the taskType property: The task type of the schedule (e.g.Get the timeZoneId property: The time zone ID (e.g.com.azure.json.JsonWriter
toJson
(com.azure.json.JsonWriter jsonWriter) void
validate()
Validates the instance.Get the weeklyRecurrence property: If the schedule will occur only some days of the week, specify the weekly recurrence.withDailyRecurrence
(DayDetails dailyRecurrence) Set the dailyRecurrence property: If the schedule will occur once each day of the week, specify the daily recurrence.withHourlyRecurrence
(HourDetails hourlyRecurrence) Set the hourlyRecurrence property: If the schedule will occur multiple times a day, specify the hourly recurrence.Set the name property: The name of the virtual machine or environment.withNotificationSettings
(NotificationSettings notificationSettings) Set the notificationSettings property: Notification settings.withStatus
(EnableStatus status) Set the status property: The status of the schedule (i.e.Set the tags property: The tags of the resource.withTargetResourceId
(String targetResourceId) Set the targetResourceId property: The resource ID to which the schedule belongs.withTaskType
(String taskType) Set the taskType property: The task type of the schedule (e.g.withTimeZoneId
(String timeZoneId) Set the timeZoneId property: The time zone ID (e.g.withWeeklyRecurrence
(WeekDetails weeklyRecurrence) Set the weeklyRecurrence property: If the schedule will occur only some days of the week, specify the weekly recurrence.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
-
ScheduleCreationParameter
public ScheduleCreationParameter()Creates an instance of ScheduleCreationParameter class.
-
-
Method Details
-
name
Get the name property: The name of the virtual machine or environment.- Returns:
- the name value.
-
withName
Set the name property: The name of the virtual machine or environment.- Parameters:
name
- the name value to set.- Returns:
- the ScheduleCreationParameter object itself.
-
location
Get the location property: The location of the new virtual machine or environment.- Returns:
- the location value.
-
tags
Get the tags property: The tags of the resource.- Returns:
- the tags value.
-
withTags
Set the tags property: The tags of the resource.- Parameters:
tags
- the tags value to set.- Returns:
- the ScheduleCreationParameter object itself.
-
status
Get the status property: The status of the schedule (i.e. Enabled, Disabled).- Returns:
- the status value.
-
withStatus
Set the status property: The status of the schedule (i.e. Enabled, Disabled).- Parameters:
status
- the status value to set.- Returns:
- the ScheduleCreationParameter object itself.
-
taskType
Get the taskType property: The task type of the schedule (e.g. LabVmsShutdownTask, LabVmAutoStart).- Returns:
- the taskType value.
-
withTaskType
Set the taskType property: The task type of the schedule (e.g. LabVmsShutdownTask, LabVmAutoStart).- Parameters:
taskType
- the taskType value to set.- Returns:
- the ScheduleCreationParameter object itself.
-
weeklyRecurrence
Get the weeklyRecurrence property: If the schedule will occur only some days of the week, specify the weekly recurrence.- Returns:
- the weeklyRecurrence value.
-
withWeeklyRecurrence
Set the weeklyRecurrence property: If the schedule will occur only some days of the week, specify the weekly recurrence.- Parameters:
weeklyRecurrence
- the weeklyRecurrence value to set.- Returns:
- the ScheduleCreationParameter object itself.
-
dailyRecurrence
Get the dailyRecurrence property: If the schedule will occur once each day of the week, specify the daily recurrence.- Returns:
- the dailyRecurrence value.
-
withDailyRecurrence
Set the dailyRecurrence property: If the schedule will occur once each day of the week, specify the daily recurrence.- Parameters:
dailyRecurrence
- the dailyRecurrence value to set.- Returns:
- the ScheduleCreationParameter object itself.
-
hourlyRecurrence
Get the hourlyRecurrence property: If the schedule will occur multiple times a day, specify the hourly recurrence.- Returns:
- the hourlyRecurrence value.
-
withHourlyRecurrence
Set the hourlyRecurrence property: If the schedule will occur multiple times a day, specify the hourly recurrence.- Parameters:
hourlyRecurrence
- the hourlyRecurrence value to set.- Returns:
- the ScheduleCreationParameter object itself.
-
timeZoneId
Get the timeZoneId property: The time zone ID (e.g. China Standard Time, Greenland Standard Time, Pacific Standard time, etc.). The possible values for this property can be found in `IReadOnlyCollection<string> TimeZoneConverter.TZConvert.KnownWindowsTimeZoneIds` (https://github.com/mattjohnsonpint/TimeZoneConverter/blob/main/README.md).- Returns:
- the timeZoneId value.
-
withTimeZoneId
Set the timeZoneId property: The time zone ID (e.g. China Standard Time, Greenland Standard Time, Pacific Standard time, etc.). The possible values for this property can be found in `IReadOnlyCollection<string> TimeZoneConverter.TZConvert.KnownWindowsTimeZoneIds` (https://github.com/mattjohnsonpint/TimeZoneConverter/blob/main/README.md).- Parameters:
timeZoneId
- the timeZoneId value to set.- Returns:
- the ScheduleCreationParameter object itself.
-
notificationSettings
Get the notificationSettings property: Notification settings.- Returns:
- the notificationSettings value.
-
withNotificationSettings
public ScheduleCreationParameter withNotificationSettings(NotificationSettings notificationSettings) Set the notificationSettings property: Notification settings.- Parameters:
notificationSettings
- the notificationSettings value to set.- Returns:
- the ScheduleCreationParameter object itself.
-
targetResourceId
Get the targetResourceId property: The resource ID to which the schedule belongs.- Returns:
- the targetResourceId value.
-
withTargetResourceId
Set the targetResourceId property: The resource ID to which the schedule belongs.- Parameters:
targetResourceId
- the targetResourceId value to set.- Returns:
- the ScheduleCreationParameter object itself.
-
validate
public void validate()Validates the instance.- Throws:
IllegalArgumentException
- thrown if the instance is not valid.
-
toJson
- Specified by:
toJson
in interfacecom.azure.json.JsonSerializable<ScheduleCreationParameter>
- Throws:
IOException
-
fromJson
public static ScheduleCreationParameter fromJson(com.azure.json.JsonReader jsonReader) throws IOException Reads an instance of ScheduleCreationParameter from the JsonReader.- Parameters:
jsonReader
- The JsonReader being read.- Returns:
- An instance of ScheduleCreationParameter 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 ScheduleCreationParameter.
-