
com.azure.resourcemanager.netapp.fluent.models.SnapshotPolicyProperties Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of azure-resourcemanager-netapp Show documentation
Show all versions of azure-resourcemanager-netapp Show documentation
This package contains Microsoft Azure SDK for NetAppFiles Management SDK. For documentation on how to use this package, please see https://aka.ms/azsdk/java/mgmt. Microsoft NetApp Files Azure Resource Provider specification. Package tag package-preview-2024-07-01-preview.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
// Code generated by Microsoft (R) AutoRest Code Generator.
package com.azure.resourcemanager.netapp.fluent.models;
import com.azure.core.annotation.Fluent;
import com.azure.resourcemanager.netapp.models.DailySchedule;
import com.azure.resourcemanager.netapp.models.HourlySchedule;
import com.azure.resourcemanager.netapp.models.MonthlySchedule;
import com.azure.resourcemanager.netapp.models.WeeklySchedule;
import com.fasterxml.jackson.annotation.JsonProperty;
/**
* Snapshot policy properties.
*/
@Fluent
public final class SnapshotPolicyProperties {
/*
* Schedule for hourly snapshots
*/
@JsonProperty(value = "hourlySchedule")
private HourlySchedule hourlySchedule;
/*
* Schedule for daily snapshots
*/
@JsonProperty(value = "dailySchedule")
private DailySchedule dailySchedule;
/*
* Schedule for weekly snapshots
*/
@JsonProperty(value = "weeklySchedule")
private WeeklySchedule weeklySchedule;
/*
* Schedule for monthly snapshots
*/
@JsonProperty(value = "monthlySchedule")
private MonthlySchedule monthlySchedule;
/*
* The property to decide policy is enabled or not
*/
@JsonProperty(value = "enabled")
private Boolean enabled;
/*
* Azure lifecycle management
*/
@JsonProperty(value = "provisioningState", access = JsonProperty.Access.WRITE_ONLY)
private String provisioningState;
/**
* Creates an instance of SnapshotPolicyProperties class.
*/
public SnapshotPolicyProperties() {
}
/**
* Get the hourlySchedule property: Schedule for hourly snapshots.
*
* @return the hourlySchedule value.
*/
public HourlySchedule hourlySchedule() {
return this.hourlySchedule;
}
/**
* Set the hourlySchedule property: Schedule for hourly snapshots.
*
* @param hourlySchedule the hourlySchedule value to set.
* @return the SnapshotPolicyProperties object itself.
*/
public SnapshotPolicyProperties withHourlySchedule(HourlySchedule hourlySchedule) {
this.hourlySchedule = hourlySchedule;
return this;
}
/**
* Get the dailySchedule property: Schedule for daily snapshots.
*
* @return the dailySchedule value.
*/
public DailySchedule dailySchedule() {
return this.dailySchedule;
}
/**
* Set the dailySchedule property: Schedule for daily snapshots.
*
* @param dailySchedule the dailySchedule value to set.
* @return the SnapshotPolicyProperties object itself.
*/
public SnapshotPolicyProperties withDailySchedule(DailySchedule dailySchedule) {
this.dailySchedule = dailySchedule;
return this;
}
/**
* Get the weeklySchedule property: Schedule for weekly snapshots.
*
* @return the weeklySchedule value.
*/
public WeeklySchedule weeklySchedule() {
return this.weeklySchedule;
}
/**
* Set the weeklySchedule property: Schedule for weekly snapshots.
*
* @param weeklySchedule the weeklySchedule value to set.
* @return the SnapshotPolicyProperties object itself.
*/
public SnapshotPolicyProperties withWeeklySchedule(WeeklySchedule weeklySchedule) {
this.weeklySchedule = weeklySchedule;
return this;
}
/**
* Get the monthlySchedule property: Schedule for monthly snapshots.
*
* @return the monthlySchedule value.
*/
public MonthlySchedule monthlySchedule() {
return this.monthlySchedule;
}
/**
* Set the monthlySchedule property: Schedule for monthly snapshots.
*
* @param monthlySchedule the monthlySchedule value to set.
* @return the SnapshotPolicyProperties object itself.
*/
public SnapshotPolicyProperties withMonthlySchedule(MonthlySchedule monthlySchedule) {
this.monthlySchedule = monthlySchedule;
return this;
}
/**
* Get the enabled property: The property to decide policy is enabled or not.
*
* @return the enabled value.
*/
public Boolean enabled() {
return this.enabled;
}
/**
* Set the enabled property: The property to decide policy is enabled or not.
*
* @param enabled the enabled value to set.
* @return the SnapshotPolicyProperties object itself.
*/
public SnapshotPolicyProperties withEnabled(Boolean enabled) {
this.enabled = enabled;
return this;
}
/**
* Get the provisioningState property: Azure lifecycle management.
*
* @return the provisioningState value.
*/
public String provisioningState() {
return this.provisioningState;
}
/**
* Validates the instance.
*
* @throws IllegalArgumentException thrown if the instance is not valid.
*/
public void validate() {
if (hourlySchedule() != null) {
hourlySchedule().validate();
}
if (dailySchedule() != null) {
dailySchedule().validate();
}
if (weeklySchedule() != null) {
weeklySchedule().validate();
}
if (monthlySchedule() != null) {
monthlySchedule().validate();
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy