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

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

import com.azure.core.annotation.Immutable;
import com.azure.resourcemanager.datalakestore.models.EncryptionConfig;
import com.azure.resourcemanager.datalakestore.models.EncryptionProvisioningState;
import com.azure.resourcemanager.datalakestore.models.EncryptionState;
import com.azure.resourcemanager.datalakestore.models.FirewallAllowAzureIpsState;
import com.azure.resourcemanager.datalakestore.models.FirewallState;
import com.azure.resourcemanager.datalakestore.models.TierType;
import com.azure.resourcemanager.datalakestore.models.TrustedIdProviderState;
import com.fasterxml.jackson.annotation.JsonProperty;
import java.util.List;

/** Data Lake Store account properties information. */
@Immutable
public final class DataLakeStoreAccountProperties extends DataLakeStoreAccountPropertiesBasic {
    /*
     * The default owner group for all new folders and files created in the Data Lake Store account.
     */
    @JsonProperty(value = "defaultGroup", access = JsonProperty.Access.WRITE_ONLY)
    private String defaultGroup;

    /*
     * The Key Vault encryption configuration.
     */
    @JsonProperty(value = "encryptionConfig", access = JsonProperty.Access.WRITE_ONLY)
    private EncryptionConfig encryptionConfig;

    /*
     * The current state of encryption for this Data Lake Store account.
     */
    @JsonProperty(value = "encryptionState", access = JsonProperty.Access.WRITE_ONLY)
    private EncryptionState encryptionState;

    /*
     * The current state of encryption provisioning for this Data Lake Store account.
     */
    @JsonProperty(value = "encryptionProvisioningState", access = JsonProperty.Access.WRITE_ONLY)
    private EncryptionProvisioningState encryptionProvisioningState;

    /*
     * The list of firewall rules associated with this Data Lake Store account.
     */
    @JsonProperty(value = "firewallRules", access = JsonProperty.Access.WRITE_ONLY)
    private List<FirewallRuleInner> firewallRules;

    /*
     * The list of virtual network rules associated with this Data Lake Store account.
     */
    @JsonProperty(value = "virtualNetworkRules", access = JsonProperty.Access.WRITE_ONLY)
    private List<VirtualNetworkRuleInner> virtualNetworkRules;

    /*
     * The current state of the IP address firewall for this Data Lake Store account.
     */
    @JsonProperty(value = "firewallState", access = JsonProperty.Access.WRITE_ONLY)
    private FirewallState firewallState;

    /*
     * The current state of allowing or disallowing IPs originating within Azure through the firewall. If the firewall
     * is disabled, this is not enforced.
     */
    @JsonProperty(value = "firewallAllowAzureIps", access = JsonProperty.Access.WRITE_ONLY)
    private FirewallAllowAzureIpsState firewallAllowAzureIps;

    /*
     * The list of trusted identity providers associated with this Data Lake Store account.
     */
    @JsonProperty(value = "trustedIdProviders", access = JsonProperty.Access.WRITE_ONLY)
    private List<TrustedIdProviderInner> trustedIdProviders;

    /*
     * The current state of the trusted identity provider feature for this Data Lake Store account.
     */
    @JsonProperty(value = "trustedIdProviderState", access = JsonProperty.Access.WRITE_ONLY)
    private TrustedIdProviderState trustedIdProviderState;

    /*
     * The commitment tier to use for next month.
     */
    @JsonProperty(value = "newTier", access = JsonProperty.Access.WRITE_ONLY)
    private TierType newTier;

    /*
     * The commitment tier in use for the current month.
     */
    @JsonProperty(value = "currentTier", access = JsonProperty.Access.WRITE_ONLY)
    private TierType currentTier;

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

    /**
     * Get the defaultGroup property: The default owner group for all new folders and files created in the Data Lake
     * Store account.
     *
     * @return the defaultGroup value.
     */
    public String defaultGroup() {
        return this.defaultGroup;
    }

    /**
     * Get the encryptionConfig property: The Key Vault encryption configuration.
     *
     * @return the encryptionConfig value.
     */
    public EncryptionConfig encryptionConfig() {
        return this.encryptionConfig;
    }

    /**
     * Get the encryptionState property: The current state of encryption for this Data Lake Store account.
     *
     * @return the encryptionState value.
     */
    public EncryptionState encryptionState() {
        return this.encryptionState;
    }

    /**
     * Get the encryptionProvisioningState property: The current state of encryption provisioning for this Data Lake
     * Store account.
     *
     * @return the encryptionProvisioningState value.
     */
    public EncryptionProvisioningState encryptionProvisioningState() {
        return this.encryptionProvisioningState;
    }

    /**
     * Get the firewallRules property: The list of firewall rules associated with this Data Lake Store account.
     *
     * @return the firewallRules value.
     */
    public List<FirewallRuleInner> firewallRules() {
        return this.firewallRules;
    }

    /**
     * Get the virtualNetworkRules property: The list of virtual network rules associated with this Data Lake Store
     * account.
     *
     * @return the virtualNetworkRules value.
     */
    public List<VirtualNetworkRuleInner> virtualNetworkRules() {
        return this.virtualNetworkRules;
    }

    /**
     * Get the firewallState property: The current state of the IP address firewall for this Data Lake Store account.
     *
     * @return the firewallState value.
     */
    public FirewallState firewallState() {
        return this.firewallState;
    }

    /**
     * Get the firewallAllowAzureIps property: The current state of allowing or disallowing IPs originating within Azure
     * through the firewall. If the firewall is disabled, this is not enforced.
     *
     * @return the firewallAllowAzureIps value.
     */
    public FirewallAllowAzureIpsState firewallAllowAzureIps() {
        return this.firewallAllowAzureIps;
    }

    /**
     * Get the trustedIdProviders property: The list of trusted identity providers associated with this Data Lake Store
     * account.
     *
     * @return the trustedIdProviders value.
     */
    public List<TrustedIdProviderInner> trustedIdProviders() {
        return this.trustedIdProviders;
    }

    /**
     * Get the trustedIdProviderState property: The current state of the trusted identity provider feature for this Data
     * Lake Store account.
     *
     * @return the trustedIdProviderState value.
     */
    public TrustedIdProviderState trustedIdProviderState() {
        return this.trustedIdProviderState;
    }

    /**
     * Get the newTier property: The commitment tier to use for next month.
     *
     * @return the newTier value.
     */
    public TierType newTier() {
        return this.newTier;
    }

    /**
     * Get the currentTier property: The commitment tier in use for the current month.
     *
     * @return the currentTier value.
     */
    public TierType currentTier() {
        return this.currentTier;
    }

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