ScheduleProfile Class
- java.
lang. Object - com.
azure. resourcemanager. compute. models. ScheduleProfile
- com.
Implements
public final class ScheduleProfile
implements JsonSerializable<ScheduleProfile>
Defines the schedule for Block-type capacity reservations. Specifies the schedule during which capacity reservation is active and VM or VMSS resource can be allocated using reservation. This property is required and only supported when the capacity reservation group type is 'Block'. The scheduleProfile, start, and end fields are immutable after creation. Minimum API version: 2025-04-01. Please refer to https://aka.ms/blockcapacityreservation for more details.
Constructor Summary
| Constructor | Description |
|---|---|
| ScheduleProfile() |
Creates an instance of Schedule |
Method Summary
| Modifier and Type | Method and Description |
|---|---|
| String |
end()
Get the end property: The required end date for block capacity reservations. |
|
static
Schedule |
fromJson(JsonReader jsonReader)
Reads an instance of Schedule |
| String |
start()
Get the start property: The required start date for block capacity reservations. |
|
Json |
toJson(JsonWriter jsonWriter) |
| void |
validate()
Validates the instance. |
|
Schedule |
withEnd(String end)
Set the end property: The required end date for block capacity reservations. |
|
Schedule |
withStart(String start)
Set the start property: The required start date for block capacity reservations. |
Methods inherited from java.lang.Object
Constructor Details
ScheduleProfile
public ScheduleProfile()
Creates an instance of ScheduleProfile class.
Method Details
end
public String end()
Get the end property: The required end date for block capacity reservations. Must be after the start date, with a duration of either 1–14 whole days or 3–26 whole weeks. Example: 2025-06-28.
Returns:
fromJson
public static ScheduleProfile fromJson(JsonReader jsonReader)
Reads an instance of ScheduleProfile from the JsonReader.
Parameters:
Returns:
Throws:
start
public String start()
Get the start property: The required start date for block capacity reservations. Must be today or within 56 days in the future. For same-day scheduling, requests must be submitted before 11:30 AM UTC. Example: 2025-06-27.
Returns:
toJson
validate
public void validate()
Validates the instance.
withEnd
public ScheduleProfile withEnd(String end)
Set the end property: The required end date for block capacity reservations. Must be after the start date, with a duration of either 1–14 whole days or 3–26 whole weeks. Example: 2025-06-28.
Parameters:
Returns:
withStart
public ScheduleProfile withStart(String start)
Set the start property: The required start date for block capacity reservations. Must be today or within 56 days in the future. For same-day scheduling, requests must be submitted before 11:30 AM UTC. Example: 2025-06-27.
Parameters:
Returns: