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

package com.azure.resourcemanager.recoveryservicessiterecovery.models;

import com.azure.core.annotation.Fluent;
import com.fasterxml.jackson.annotation.JsonProperty;
import java.util.List;

/** VMware/Physical specific Disk Details. */
@Fluent
public final class InMageDiskDetails {
    /*
     * The disk Id.
     */
    @JsonProperty(value = "diskId")
    private String diskId;

    /*
     * The disk name.
     */
    @JsonProperty(value = "diskName")
    private String diskName;

    /*
     * The disk size in MB.
     */
    @JsonProperty(value = "diskSizeInMB")
    private String diskSizeInMB;

    /*
     * Whether disk is system disk or data disk.
     */
    @JsonProperty(value = "diskType")
    private String diskType;

    /*
     * Whether disk is dynamic disk or basic disk.
     */
    @JsonProperty(value = "diskConfiguration")
    private String diskConfiguration;

    /*
     * Volumes of the disk.
     */
    @JsonProperty(value = "volumeList")
    private List<DiskVolumeDetails> volumeList;

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

    /**
     * Get the diskId property: The disk Id.
     *
     * @return the diskId value.
     */
    public String diskId() {
        return this.diskId;
    }

    /**
     * Set the diskId property: The disk Id.
     *
     * @param diskId the diskId value to set.
     * @return the InMageDiskDetails object itself.
     */
    public InMageDiskDetails withDiskId(String diskId) {
        this.diskId = diskId;
        return this;
    }

    /**
     * Get the diskName property: The disk name.
     *
     * @return the diskName value.
     */
    public String diskName() {
        return this.diskName;
    }

    /**
     * Set the diskName property: The disk name.
     *
     * @param diskName the diskName value to set.
     * @return the InMageDiskDetails object itself.
     */
    public InMageDiskDetails withDiskName(String diskName) {
        this.diskName = diskName;
        return this;
    }

    /**
     * Get the diskSizeInMB property: The disk size in MB.
     *
     * @return the diskSizeInMB value.
     */
    public String diskSizeInMB() {
        return this.diskSizeInMB;
    }

    /**
     * Set the diskSizeInMB property: The disk size in MB.
     *
     * @param diskSizeInMB the diskSizeInMB value to set.
     * @return the InMageDiskDetails object itself.
     */
    public InMageDiskDetails withDiskSizeInMB(String diskSizeInMB) {
        this.diskSizeInMB = diskSizeInMB;
        return this;
    }

    /**
     * Get the diskType property: Whether disk is system disk or data disk.
     *
     * @return the diskType value.
     */
    public String diskType() {
        return this.diskType;
    }

    /**
     * Set the diskType property: Whether disk is system disk or data disk.
     *
     * @param diskType the diskType value to set.
     * @return the InMageDiskDetails object itself.
     */
    public InMageDiskDetails withDiskType(String diskType) {
        this.diskType = diskType;
        return this;
    }

    /**
     * Get the diskConfiguration property: Whether disk is dynamic disk or basic disk.
     *
     * @return the diskConfiguration value.
     */
    public String diskConfiguration() {
        return this.diskConfiguration;
    }

    /**
     * Set the diskConfiguration property: Whether disk is dynamic disk or basic disk.
     *
     * @param diskConfiguration the diskConfiguration value to set.
     * @return the InMageDiskDetails object itself.
     */
    public InMageDiskDetails withDiskConfiguration(String diskConfiguration) {
        this.diskConfiguration = diskConfiguration;
        return this;
    }

    /**
     * Get the volumeList property: Volumes of the disk.
     *
     * @return the volumeList value.
     */
    public List<DiskVolumeDetails> volumeList() {
        return this.volumeList;
    }

    /**
     * Set the volumeList property: Volumes of the disk.
     *
     * @param volumeList the volumeList value to set.
     * @return the InMageDiskDetails object itself.
     */
    public InMageDiskDetails withVolumeList(List<DiskVolumeDetails> volumeList) {
        this.volumeList = volumeList;
        return this;
    }

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