Class YearlyRetentionSchedule
java.lang.Object
com.azure.resourcemanager.recoveryservicesbackup.models.YearlyRetentionSchedule
Yearly retention schedule.
-
Constructor Summary
ConstructorDescriptionCreates an instance of YearlyRetentionSchedule class. -
Method Summary
Modifier and TypeMethodDescriptionGet the monthsOfYear property: List of months of year of yearly retention policy.Get the retentionDuration property: Retention duration of retention Policy.Get the retentionScheduleDaily property: Daily retention format for yearly retention policy.Get the retentionScheduleFormatType property: Retention schedule format for yearly retention policy.Get the retentionScheduleWeekly property: Weekly retention format for yearly retention policy.Get the retentionTimes property: Retention times of retention policy.void
validate()
Validates the instance.withMonthsOfYear
(List<MonthOfYear> monthsOfYear) Set the monthsOfYear property: List of months of year of yearly retention policy.withRetentionDuration
(RetentionDuration retentionDuration) Set the retentionDuration property: Retention duration of retention Policy.withRetentionScheduleDaily
(DailyRetentionFormat retentionScheduleDaily) Set the retentionScheduleDaily property: Daily retention format for yearly retention policy.withRetentionScheduleFormatType
(RetentionScheduleFormat retentionScheduleFormatType) Set the retentionScheduleFormatType property: Retention schedule format for yearly retention policy.withRetentionScheduleWeekly
(WeeklyRetentionFormat retentionScheduleWeekly) Set the retentionScheduleWeekly property: Weekly retention format for yearly retention policy.withRetentionTimes
(List<OffsetDateTime> retentionTimes) Set the retentionTimes property: Retention times of retention policy.
-
Constructor Details
-
YearlyRetentionSchedule
public YearlyRetentionSchedule()Creates an instance of YearlyRetentionSchedule class.
-
-
Method Details
-
retentionScheduleFormatType
Get the retentionScheduleFormatType property: Retention schedule format for yearly retention policy.- Returns:
- the retentionScheduleFormatType value.
-
withRetentionScheduleFormatType
public YearlyRetentionSchedule withRetentionScheduleFormatType(RetentionScheduleFormat retentionScheduleFormatType) Set the retentionScheduleFormatType property: Retention schedule format for yearly retention policy.- Parameters:
retentionScheduleFormatType
- the retentionScheduleFormatType value to set.- Returns:
- the YearlyRetentionSchedule object itself.
-
monthsOfYear
Get the monthsOfYear property: List of months of year of yearly retention policy.- Returns:
- the monthsOfYear value.
-
withMonthsOfYear
Set the monthsOfYear property: List of months of year of yearly retention policy.- Parameters:
monthsOfYear
- the monthsOfYear value to set.- Returns:
- the YearlyRetentionSchedule object itself.
-
retentionScheduleDaily
Get the retentionScheduleDaily property: Daily retention format for yearly retention policy.- Returns:
- the retentionScheduleDaily value.
-
withRetentionScheduleDaily
public YearlyRetentionSchedule withRetentionScheduleDaily(DailyRetentionFormat retentionScheduleDaily) Set the retentionScheduleDaily property: Daily retention format for yearly retention policy.- Parameters:
retentionScheduleDaily
- the retentionScheduleDaily value to set.- Returns:
- the YearlyRetentionSchedule object itself.
-
retentionScheduleWeekly
Get the retentionScheduleWeekly property: Weekly retention format for yearly retention policy.- Returns:
- the retentionScheduleWeekly value.
-
withRetentionScheduleWeekly
public YearlyRetentionSchedule withRetentionScheduleWeekly(WeeklyRetentionFormat retentionScheduleWeekly) Set the retentionScheduleWeekly property: Weekly retention format for yearly retention policy.- Parameters:
retentionScheduleWeekly
- the retentionScheduleWeekly value to set.- Returns:
- the YearlyRetentionSchedule object itself.
-
retentionTimes
Get the retentionTimes property: Retention times of retention policy.- Returns:
- the retentionTimes value.
-
withRetentionTimes
Set the retentionTimes property: Retention times of retention policy.- Parameters:
retentionTimes
- the retentionTimes value to set.- Returns:
- the YearlyRetentionSchedule object itself.
-
retentionDuration
Get the retentionDuration property: Retention duration of retention Policy.- Returns:
- the retentionDuration value.
-
withRetentionDuration
Set the retentionDuration property: Retention duration of retention Policy.- Parameters:
retentionDuration
- the retentionDuration value to set.- Returns:
- the YearlyRetentionSchedule object itself.
-
validate
public void validate()Validates the instance.- Throws:
IllegalArgumentException
- thrown if the instance is not valid.
-