// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
// Code generated by Microsoft (R) AutoRest Code Generator.

package com.azure.resourcemanager.workloads.models;

import com.azure.core.annotation.Fluent;
import com.fasterxml.jackson.annotation.JsonProperty;

/** The supported disk size details for a disk type. */
@Fluent
public final class DiskDetails {
    /*
     * The type of disk sku. For example, Standard_LRS, Standard_ZRS, Premium_LRS, Premium_ZRS.
     */
    @JsonProperty(value = "sku")
    private DiskSku sku;

    /*
     * The disk size in GB.
     */
    @JsonProperty(value = "sizeGB")
    private Long sizeGB;

    /*
     * The minimum supported disk count.
     */
    @JsonProperty(value = "minimumSupportedDiskCount")
    private Long minimumSupportedDiskCount;

    /*
     * The maximum supported disk count.
     */
    @JsonProperty(value = "maximumSupportedDiskCount")
    private Long maximumSupportedDiskCount;

    /*
     * The disk Iops.
     */
    @JsonProperty(value = "iopsReadWrite")
    private Long iopsReadWrite;

    /*
     * The disk provisioned throughput in MBps.
     */
    @JsonProperty(value = "mbpsReadWrite")
    private Long mbpsReadWrite;

    /*
     * The disk tier, e.g. P10, E10.
     */
    @JsonProperty(value = "diskTier")
    private String diskTier;

    /** Creates an instance of DiskDetails class. */
    public DiskDetails() {
    }

    /**
     * Get the sku property: The type of disk sku. For example, Standard_LRS, Standard_ZRS, Premium_LRS, Premium_ZRS.
     *
     * @return the sku value.
     */
    public DiskSku sku() {
        return this.sku;
    }

    /**
     * Set the sku property: The type of disk sku. For example, Standard_LRS, Standard_ZRS, Premium_LRS, Premium_ZRS.
     *
     * @param sku the sku value to set.
     * @return the DiskDetails object itself.
     */
    public DiskDetails withSku(DiskSku sku) {
        this.sku = sku;
        return this;
    }

    /**
     * Get the sizeGB property: The disk size in GB.
     *
     * @return the sizeGB value.
     */
    public Long sizeGB() {
        return this.sizeGB;
    }

    /**
     * Set the sizeGB property: The disk size in GB.
     *
     * @param sizeGB the sizeGB value to set.
     * @return the DiskDetails object itself.
     */
    public DiskDetails withSizeGB(Long sizeGB) {
        this.sizeGB = sizeGB;
        return this;
    }

    /**
     * Get the minimumSupportedDiskCount property: The minimum supported disk count.
     *
     * @return the minimumSupportedDiskCount value.
     */
    public Long minimumSupportedDiskCount() {
        return this.minimumSupportedDiskCount;
    }

    /**
     * Set the minimumSupportedDiskCount property: The minimum supported disk count.
     *
     * @param minimumSupportedDiskCount the minimumSupportedDiskCount value to set.
     * @return the DiskDetails object itself.
     */
    public DiskDetails withMinimumSupportedDiskCount(Long minimumSupportedDiskCount) {
        this.minimumSupportedDiskCount = minimumSupportedDiskCount;
        return this;
    }

    /**
     * Get the maximumSupportedDiskCount property: The maximum supported disk count.
     *
     * @return the maximumSupportedDiskCount value.
     */
    public Long maximumSupportedDiskCount() {
        return this.maximumSupportedDiskCount;
    }

    /**
     * Set the maximumSupportedDiskCount property: The maximum supported disk count.
     *
     * @param maximumSupportedDiskCount the maximumSupportedDiskCount value to set.
     * @return the DiskDetails object itself.
     */
    public DiskDetails withMaximumSupportedDiskCount(Long maximumSupportedDiskCount) {
        this.maximumSupportedDiskCount = maximumSupportedDiskCount;
        return this;
    }

    /**
     * Get the iopsReadWrite property: The disk Iops.
     *
     * @return the iopsReadWrite value.
     */
    public Long iopsReadWrite() {
        return this.iopsReadWrite;
    }

    /**
     * Set the iopsReadWrite property: The disk Iops.
     *
     * @param iopsReadWrite the iopsReadWrite value to set.
     * @return the DiskDetails object itself.
     */
    public DiskDetails withIopsReadWrite(Long iopsReadWrite) {
        this.iopsReadWrite = iopsReadWrite;
        return this;
    }

    /**
     * Get the mbpsReadWrite property: The disk provisioned throughput in MBps.
     *
     * @return the mbpsReadWrite value.
     */
    public Long mbpsReadWrite() {
        return this.mbpsReadWrite;
    }

    /**
     * Set the mbpsReadWrite property: The disk provisioned throughput in MBps.
     *
     * @param mbpsReadWrite the mbpsReadWrite value to set.
     * @return the DiskDetails object itself.
     */
    public DiskDetails withMbpsReadWrite(Long mbpsReadWrite) {
        this.mbpsReadWrite = mbpsReadWrite;
        return this;
    }

    /**
     * Get the diskTier property: The disk tier, e.g. P10, E10.
     *
     * @return the diskTier value.
     */
    public String diskTier() {
        return this.diskTier;
    }

    /**
     * Set the diskTier property: The disk tier, e.g. P10, E10.
     *
     * @param diskTier the diskTier value to set.
     * @return the DiskDetails object itself.
     */
    public DiskDetails withDiskTier(String diskTier) {
        this.diskTier = diskTier;
        return this;
    }

    /**
     * Validates the instance.
     *
     * @throws IllegalArgumentException thrown if the instance is not valid.
     */
    public void validate() {
        if (sku() != null) {
            sku().validate();
        }
    }
}
