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

package com.azure.resourcemanager.vmwarecloudsimple.fluent.models;

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

/** Properties of private. */
@Fluent
public final class PrivateCloudProperties {
    /*
     * Availability Zone id, e.g. "az1"
     */
    @JsonProperty(value = "availabilityZoneId")
    private String availabilityZoneId;

    /*
     * Availability Zone name, e.g. "Availability Zone 1"
     */
    @JsonProperty(value = "availabilityZoneName")
    private String availabilityZoneName;

    /*
     * Number of clusters
     */
    @JsonProperty(value = "clustersNumber")
    private Integer clustersNumber;

    /*
     * User's emails who created cloud
     */
    @JsonProperty(value = "createdBy")
    private String createdBy;

    /*
     * When private cloud was created
     */
    @JsonProperty(value = "createdOn")
    private OffsetDateTime createdOn;

    /*
     * Array of DNS servers
     */
    @JsonProperty(value = "dnsServers")
    private List<String> dnsServers;

    /*
     * Expiration date of PC
     */
    @JsonProperty(value = "expires")
    private String expires;

    /*
     * Nsx Type, e.g. "Advanced"
     */
    @JsonProperty(value = "nsxType")
    private String nsxType;

    /*
     * Placement Group id, e.g. "n1"
     */
    @JsonProperty(value = "placementGroupId")
    private String placementGroupId;

    /*
     * Placement Group name
     */
    @JsonProperty(value = "placementGroupName")
    private String placementGroupName;

    /*
     * Id of a private cloud
     */
    @JsonProperty(value = "privateCloudId")
    private UUID privateCloudId;

    /*
     * The list of Resource Pools
     */
    @JsonProperty(value = "resourcePools")
    private List<ResourcePoolInner> resourcePools;

    /*
     * Private Cloud state, e.g. "operational"
     */
    @JsonProperty(value = "state")
    private String state;

    /*
     * Number of cores
     */
    @JsonProperty(value = "totalCpuCores")
    private Integer totalCpuCores;

    /*
     * Number of nodes
     */
    @JsonProperty(value = "totalNodes")
    private Integer totalNodes;

    /*
     * Memory size
     */
    @JsonProperty(value = "totalRam")
    private Integer totalRam;

    /*
     * Disk space in TB
     */
    @JsonProperty(value = "totalStorage")
    private Float totalStorage;

    /*
     * Virtualization type e.g. "vSphere"
     */
    @JsonProperty(value = "type")
    private String type;

    /*
     * e.g. "6.5u2"
     */
    @JsonProperty(value = "vSphereVersion")
    private String vSphereVersion;

    /*
     * FQDN for vcenter access
     */
    @JsonProperty(value = "vcenterFqdn")
    private String vcenterFqdn;

    /*
     * Vcenter ip address
     */
    @JsonProperty(value = "vcenterRefid")
    private String vcenterRefid;

    /*
     * The list of Virtual Machine Templates
     */
    @JsonProperty(value = "virtualMachineTemplates")
    private List<VirtualMachineTemplateInner> virtualMachineTemplates;

    /*
     * The list of Virtual Networks
     */
    @JsonProperty(value = "virtualNetworks")
    private List<VirtualNetworkInner> virtualNetworks;

    /*
     * Is vRealize Operations Manager enabled/disabled
     */
    @JsonProperty(value = "vrOpsEnabled")
    private Boolean vrOpsEnabled;

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

    /**
     * Get the availabilityZoneId property: Availability Zone id, e.g. "az1".
     *
     * @return the availabilityZoneId value.
     */
    public String availabilityZoneId() {
        return this.availabilityZoneId;
    }

    /**
     * Set the availabilityZoneId property: Availability Zone id, e.g. "az1".
     *
     * @param availabilityZoneId the availabilityZoneId value to set.
     * @return the PrivateCloudProperties object itself.
     */
    public PrivateCloudProperties withAvailabilityZoneId(String availabilityZoneId) {
        this.availabilityZoneId = availabilityZoneId;
        return this;
    }

    /**
     * Get the availabilityZoneName property: Availability Zone name, e.g. "Availability Zone 1".
     *
     * @return the availabilityZoneName value.
     */
    public String availabilityZoneName() {
        return this.availabilityZoneName;
    }

    /**
     * Set the availabilityZoneName property: Availability Zone name, e.g. "Availability Zone 1".
     *
     * @param availabilityZoneName the availabilityZoneName value to set.
     * @return the PrivateCloudProperties object itself.
     */
    public PrivateCloudProperties withAvailabilityZoneName(String availabilityZoneName) {
        this.availabilityZoneName = availabilityZoneName;
        return this;
    }

    /**
     * Get the clustersNumber property: Number of clusters.
     *
     * @return the clustersNumber value.
     */
    public Integer clustersNumber() {
        return this.clustersNumber;
    }

    /**
     * Set the clustersNumber property: Number of clusters.
     *
     * @param clustersNumber the clustersNumber value to set.
     * @return the PrivateCloudProperties object itself.
     */
    public PrivateCloudProperties withClustersNumber(Integer clustersNumber) {
        this.clustersNumber = clustersNumber;
        return this;
    }

    /**
     * Get the createdBy property: User's emails who created cloud.
     *
     * @return the createdBy value.
     */
    public String createdBy() {
        return this.createdBy;
    }

    /**
     * Set the createdBy property: User's emails who created cloud.
     *
     * @param createdBy the createdBy value to set.
     * @return the PrivateCloudProperties object itself.
     */
    public PrivateCloudProperties withCreatedBy(String createdBy) {
        this.createdBy = createdBy;
        return this;
    }

    /**
     * Get the createdOn property: When private cloud was created.
     *
     * @return the createdOn value.
     */
    public OffsetDateTime createdOn() {
        return this.createdOn;
    }

    /**
     * Set the createdOn property: When private cloud was created.
     *
     * @param createdOn the createdOn value to set.
     * @return the PrivateCloudProperties object itself.
     */
    public PrivateCloudProperties withCreatedOn(OffsetDateTime createdOn) {
        this.createdOn = createdOn;
        return this;
    }

    /**
     * Get the dnsServers property: Array of DNS servers.
     *
     * @return the dnsServers value.
     */
    public List<String> dnsServers() {
        return this.dnsServers;
    }

    /**
     * Set the dnsServers property: Array of DNS servers.
     *
     * @param dnsServers the dnsServers value to set.
     * @return the PrivateCloudProperties object itself.
     */
    public PrivateCloudProperties withDnsServers(List<String> dnsServers) {
        this.dnsServers = dnsServers;
        return this;
    }

    /**
     * Get the expires property: Expiration date of PC.
     *
     * @return the expires value.
     */
    public String expires() {
        return this.expires;
    }

    /**
     * Set the expires property: Expiration date of PC.
     *
     * @param expires the expires value to set.
     * @return the PrivateCloudProperties object itself.
     */
    public PrivateCloudProperties withExpires(String expires) {
        this.expires = expires;
        return this;
    }

    /**
     * Get the nsxType property: Nsx Type, e.g. "Advanced".
     *
     * @return the nsxType value.
     */
    public String nsxType() {
        return this.nsxType;
    }

    /**
     * Set the nsxType property: Nsx Type, e.g. "Advanced".
     *
     * @param nsxType the nsxType value to set.
     * @return the PrivateCloudProperties object itself.
     */
    public PrivateCloudProperties withNsxType(String nsxType) {
        this.nsxType = nsxType;
        return this;
    }

    /**
     * Get the placementGroupId property: Placement Group id, e.g. "n1".
     *
     * @return the placementGroupId value.
     */
    public String placementGroupId() {
        return this.placementGroupId;
    }

    /**
     * Set the placementGroupId property: Placement Group id, e.g. "n1".
     *
     * @param placementGroupId the placementGroupId value to set.
     * @return the PrivateCloudProperties object itself.
     */
    public PrivateCloudProperties withPlacementGroupId(String placementGroupId) {
        this.placementGroupId = placementGroupId;
        return this;
    }

    /**
     * Get the placementGroupName property: Placement Group name.
     *
     * @return the placementGroupName value.
     */
    public String placementGroupName() {
        return this.placementGroupName;
    }

    /**
     * Set the placementGroupName property: Placement Group name.
     *
     * @param placementGroupName the placementGroupName value to set.
     * @return the PrivateCloudProperties object itself.
     */
    public PrivateCloudProperties withPlacementGroupName(String placementGroupName) {
        this.placementGroupName = placementGroupName;
        return this;
    }

    /**
     * Get the privateCloudId property: Id of a private cloud.
     *
     * @return the privateCloudId value.
     */
    public UUID privateCloudId() {
        return this.privateCloudId;
    }

    /**
     * Set the privateCloudId property: Id of a private cloud.
     *
     * @param privateCloudId the privateCloudId value to set.
     * @return the PrivateCloudProperties object itself.
     */
    public PrivateCloudProperties withPrivateCloudId(UUID privateCloudId) {
        this.privateCloudId = privateCloudId;
        return this;
    }

    /**
     * Get the resourcePools property: The list of Resource Pools.
     *
     * @return the resourcePools value.
     */
    public List<ResourcePoolInner> resourcePools() {
        return this.resourcePools;
    }

    /**
     * Set the resourcePools property: The list of Resource Pools.
     *
     * @param resourcePools the resourcePools value to set.
     * @return the PrivateCloudProperties object itself.
     */
    public PrivateCloudProperties withResourcePools(List<ResourcePoolInner> resourcePools) {
        this.resourcePools = resourcePools;
        return this;
    }

    /**
     * Get the state property: Private Cloud state, e.g. "operational".
     *
     * @return the state value.
     */
    public String state() {
        return this.state;
    }

    /**
     * Set the state property: Private Cloud state, e.g. "operational".
     *
     * @param state the state value to set.
     * @return the PrivateCloudProperties object itself.
     */
    public PrivateCloudProperties withState(String state) {
        this.state = state;
        return this;
    }

    /**
     * Get the totalCpuCores property: Number of cores.
     *
     * @return the totalCpuCores value.
     */
    public Integer totalCpuCores() {
        return this.totalCpuCores;
    }

    /**
     * Set the totalCpuCores property: Number of cores.
     *
     * @param totalCpuCores the totalCpuCores value to set.
     * @return the PrivateCloudProperties object itself.
     */
    public PrivateCloudProperties withTotalCpuCores(Integer totalCpuCores) {
        this.totalCpuCores = totalCpuCores;
        return this;
    }

    /**
     * Get the totalNodes property: Number of nodes.
     *
     * @return the totalNodes value.
     */
    public Integer totalNodes() {
        return this.totalNodes;
    }

    /**
     * Set the totalNodes property: Number of nodes.
     *
     * @param totalNodes the totalNodes value to set.
     * @return the PrivateCloudProperties object itself.
     */
    public PrivateCloudProperties withTotalNodes(Integer totalNodes) {
        this.totalNodes = totalNodes;
        return this;
    }

    /**
     * Get the totalRam property: Memory size.
     *
     * @return the totalRam value.
     */
    public Integer totalRam() {
        return this.totalRam;
    }

    /**
     * Set the totalRam property: Memory size.
     *
     * @param totalRam the totalRam value to set.
     * @return the PrivateCloudProperties object itself.
     */
    public PrivateCloudProperties withTotalRam(Integer totalRam) {
        this.totalRam = totalRam;
        return this;
    }

    /**
     * Get the totalStorage property: Disk space in TB.
     *
     * @return the totalStorage value.
     */
    public Float totalStorage() {
        return this.totalStorage;
    }

    /**
     * Set the totalStorage property: Disk space in TB.
     *
     * @param totalStorage the totalStorage value to set.
     * @return the PrivateCloudProperties object itself.
     */
    public PrivateCloudProperties withTotalStorage(Float totalStorage) {
        this.totalStorage = totalStorage;
        return this;
    }

    /**
     * Get the type property: Virtualization type e.g. "vSphere".
     *
     * @return the type value.
     */
    public String type() {
        return this.type;
    }

    /**
     * Set the type property: Virtualization type e.g. "vSphere".
     *
     * @param type the type value to set.
     * @return the PrivateCloudProperties object itself.
     */
    public PrivateCloudProperties withType(String type) {
        this.type = type;
        return this;
    }

    /**
     * Get the vSphereVersion property: e.g. "6.5u2".
     *
     * @return the vSphereVersion value.
     */
    public String vSphereVersion() {
        return this.vSphereVersion;
    }

    /**
     * Set the vSphereVersion property: e.g. "6.5u2".
     *
     * @param vSphereVersion the vSphereVersion value to set.
     * @return the PrivateCloudProperties object itself.
     */
    public PrivateCloudProperties withVSphereVersion(String vSphereVersion) {
        this.vSphereVersion = vSphereVersion;
        return this;
    }

    /**
     * Get the vcenterFqdn property: FQDN for vcenter access.
     *
     * @return the vcenterFqdn value.
     */
    public String vcenterFqdn() {
        return this.vcenterFqdn;
    }

    /**
     * Set the vcenterFqdn property: FQDN for vcenter access.
     *
     * @param vcenterFqdn the vcenterFqdn value to set.
     * @return the PrivateCloudProperties object itself.
     */
    public PrivateCloudProperties withVcenterFqdn(String vcenterFqdn) {
        this.vcenterFqdn = vcenterFqdn;
        return this;
    }

    /**
     * Get the vcenterRefid property: Vcenter ip address.
     *
     * @return the vcenterRefid value.
     */
    public String vcenterRefid() {
        return this.vcenterRefid;
    }

    /**
     * Set the vcenterRefid property: Vcenter ip address.
     *
     * @param vcenterRefid the vcenterRefid value to set.
     * @return the PrivateCloudProperties object itself.
     */
    public PrivateCloudProperties withVcenterRefid(String vcenterRefid) {
        this.vcenterRefid = vcenterRefid;
        return this;
    }

    /**
     * Get the virtualMachineTemplates property: The list of Virtual Machine Templates.
     *
     * @return the virtualMachineTemplates value.
     */
    public List<VirtualMachineTemplateInner> virtualMachineTemplates() {
        return this.virtualMachineTemplates;
    }

    /**
     * Set the virtualMachineTemplates property: The list of Virtual Machine Templates.
     *
     * @param virtualMachineTemplates the virtualMachineTemplates value to set.
     * @return the PrivateCloudProperties object itself.
     */
    public PrivateCloudProperties withVirtualMachineTemplates(
        List<VirtualMachineTemplateInner> virtualMachineTemplates) {
        this.virtualMachineTemplates = virtualMachineTemplates;
        return this;
    }

    /**
     * Get the virtualNetworks property: The list of Virtual Networks.
     *
     * @return the virtualNetworks value.
     */
    public List<VirtualNetworkInner> virtualNetworks() {
        return this.virtualNetworks;
    }

    /**
     * Set the virtualNetworks property: The list of Virtual Networks.
     *
     * @param virtualNetworks the virtualNetworks value to set.
     * @return the PrivateCloudProperties object itself.
     */
    public PrivateCloudProperties withVirtualNetworks(List<VirtualNetworkInner> virtualNetworks) {
        this.virtualNetworks = virtualNetworks;
        return this;
    }

    /**
     * Get the vrOpsEnabled property: Is vRealize Operations Manager enabled/disabled.
     *
     * @return the vrOpsEnabled value.
     */
    public Boolean vrOpsEnabled() {
        return this.vrOpsEnabled;
    }

    /**
     * Set the vrOpsEnabled property: Is vRealize Operations Manager enabled/disabled.
     *
     * @param vrOpsEnabled the vrOpsEnabled value to set.
     * @return the PrivateCloudProperties object itself.
     */
    public PrivateCloudProperties withVrOpsEnabled(Boolean vrOpsEnabled) {
        this.vrOpsEnabled = vrOpsEnabled;
        return this;
    }

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