// 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.RegionInfoAvailabilityZoneMappingsItem;
import com.azure.resourcemanager.netapp.models.RegionStorageToNetworkProximity;
import com.fasterxml.jackson.annotation.JsonProperty;
import java.util.List;

/** Provides region specific information. */
@Fluent
public final class RegionInfoInner {
    /*
     * Storage to Network Proximity
     *
     * Provides storage to network proximity information in the region.
     */
    @JsonProperty(value = "storageToNetworkProximity")
    private RegionStorageToNetworkProximity storageToNetworkProximity;

    /*
     * Logical availability zone mappings.
     *
     * Provides logical availability zone mappings for the subscription for a region.
     */
    @JsonProperty(value = "availabilityZoneMappings")
    private List<RegionInfoAvailabilityZoneMappingsItem> availabilityZoneMappings;

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

    /**
     * Get the storageToNetworkProximity property: Storage to Network Proximity
     *
     * <p>Provides storage to network proximity information in the region.
     *
     * @return the storageToNetworkProximity value.
     */
    public RegionStorageToNetworkProximity storageToNetworkProximity() {
        return this.storageToNetworkProximity;
    }

    /**
     * Set the storageToNetworkProximity property: Storage to Network Proximity
     *
     * <p>Provides storage to network proximity information in the region.
     *
     * @param storageToNetworkProximity the storageToNetworkProximity value to set.
     * @return the RegionInfoInner object itself.
     */
    public RegionInfoInner withStorageToNetworkProximity(RegionStorageToNetworkProximity storageToNetworkProximity) {
        this.storageToNetworkProximity = storageToNetworkProximity;
        return this;
    }

    /**
     * Get the availabilityZoneMappings property: Logical availability zone mappings.
     *
     * <p>Provides logical availability zone mappings for the subscription for a region.
     *
     * @return the availabilityZoneMappings value.
     */
    public List<RegionInfoAvailabilityZoneMappingsItem> availabilityZoneMappings() {
        return this.availabilityZoneMappings;
    }

    /**
     * Set the availabilityZoneMappings property: Logical availability zone mappings.
     *
     * <p>Provides logical availability zone mappings for the subscription for a region.
     *
     * @param availabilityZoneMappings the availabilityZoneMappings value to set.
     * @return the RegionInfoInner object itself.
     */
    public RegionInfoInner withAvailabilityZoneMappings(
        List<RegionInfoAvailabilityZoneMappingsItem> availabilityZoneMappings) {
        this.availabilityZoneMappings = availabilityZoneMappings;
        return this;
    }

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