// *** WARNING: this file was generated by pulumi-java-gen. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***

package com.pulumi.azure.media.inputs;

import com.pulumi.azure.media.inputs.ServiceAccountEncryptionArgs;
import com.pulumi.azure.media.inputs.ServiceAccountIdentityArgs;
import com.pulumi.azure.media.inputs.ServiceAccountKeyDeliveryAccessControlArgs;
import com.pulumi.azure.media.inputs.ServiceAccountStorageAccountArgs;
import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
import java.lang.Boolean;
import java.lang.String;
import java.util.List;
import java.util.Map;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;


public final class ServiceAccountState extends com.pulumi.resources.ResourceArgs {

    public static final ServiceAccountState Empty = new ServiceAccountState();

    /**
     * An `encryption` block as defined below.
     * 
     */
    @Import(name="encryption")
    private @Nullable Output<ServiceAccountEncryptionArgs> encryption;

    /**
     * @return An `encryption` block as defined below.
     * 
     */
    public Optional<Output<ServiceAccountEncryptionArgs>> encryption() {
        return Optional.ofNullable(this.encryption);
    }

    /**
     * An `identity` block as defined below.
     * 
     */
    @Import(name="identity")
    private @Nullable Output<ServiceAccountIdentityArgs> identity;

    /**
     * @return An `identity` block as defined below.
     * 
     */
    public Optional<Output<ServiceAccountIdentityArgs>> identity() {
        return Optional.ofNullable(this.identity);
    }

    /**
     * A `key_delivery_access_control` block as defined below.
     * 
     */
    @Import(name="keyDeliveryAccessControl")
    private @Nullable Output<ServiceAccountKeyDeliveryAccessControlArgs> keyDeliveryAccessControl;

    /**
     * @return A `key_delivery_access_control` block as defined below.
     * 
     */
    public Optional<Output<ServiceAccountKeyDeliveryAccessControlArgs>> keyDeliveryAccessControl() {
        return Optional.ofNullable(this.keyDeliveryAccessControl);
    }

    /**
     * Specifies the supported Azure location where the resource exists. Changing this forces a new resource to be created.
     * 
     */
    @Import(name="location")
    private @Nullable Output<String> location;

    /**
     * @return Specifies the supported Azure location where the resource exists. Changing this forces a new resource to be created.
     * 
     */
    public Optional<Output<String>> location() {
        return Optional.ofNullable(this.location);
    }

    /**
     * Specifies the name of the Media Services Account. Only lowercase Alphanumeric characters allowed. Changing this forces a new resource to be created.
     * 
     */
    @Import(name="name")
    private @Nullable Output<String> name;

    /**
     * @return Specifies the name of the Media Services Account. Only lowercase Alphanumeric characters allowed. Changing this forces a new resource to be created.
     * 
     */
    public Optional<Output<String>> name() {
        return Optional.ofNullable(this.name);
    }

    /**
     * Whether public network access is allowed for this server. Defaults to `true`.
     * 
     */
    @Import(name="publicNetworkAccessEnabled")
    private @Nullable Output<Boolean> publicNetworkAccessEnabled;

    /**
     * @return Whether public network access is allowed for this server. Defaults to `true`.
     * 
     */
    public Optional<Output<Boolean>> publicNetworkAccessEnabled() {
        return Optional.ofNullable(this.publicNetworkAccessEnabled);
    }

    /**
     * The name of the resource group in which to create the Media Services Account. Changing this forces a new resource to be created.
     * 
     */
    @Import(name="resourceGroupName")
    private @Nullable Output<String> resourceGroupName;

    /**
     * @return The name of the resource group in which to create the Media Services Account. Changing this forces a new resource to be created.
     * 
     */
    public Optional<Output<String>> resourceGroupName() {
        return Optional.ofNullable(this.resourceGroupName);
    }

    /**
     * One or more `storage_account` blocks as defined below.
     * 
     */
    @Import(name="storageAccounts")
    private @Nullable Output<List<ServiceAccountStorageAccountArgs>> storageAccounts;

    /**
     * @return One or more `storage_account` blocks as defined below.
     * 
     */
    public Optional<Output<List<ServiceAccountStorageAccountArgs>>> storageAccounts() {
        return Optional.ofNullable(this.storageAccounts);
    }

    /**
     * Specifies the storage authentication type. Possible value is `ManagedIdentity` or `System`.
     * 
     */
    @Import(name="storageAuthenticationType")
    private @Nullable Output<String> storageAuthenticationType;

    /**
     * @return Specifies the storage authentication type. Possible value is `ManagedIdentity` or `System`.
     * 
     */
    public Optional<Output<String>> storageAuthenticationType() {
        return Optional.ofNullable(this.storageAuthenticationType);
    }

    /**
     * A mapping of tags assigned to the resource.
     * 
     */
    @Import(name="tags")
    private @Nullable Output<Map<String,String>> tags;

    /**
     * @return A mapping of tags assigned to the resource.
     * 
     */
    public Optional<Output<Map<String,String>>> tags() {
        return Optional.ofNullable(this.tags);
    }

    private ServiceAccountState() {}

    private ServiceAccountState(ServiceAccountState $) {
        this.encryption = $.encryption;
        this.identity = $.identity;
        this.keyDeliveryAccessControl = $.keyDeliveryAccessControl;
        this.location = $.location;
        this.name = $.name;
        this.publicNetworkAccessEnabled = $.publicNetworkAccessEnabled;
        this.resourceGroupName = $.resourceGroupName;
        this.storageAccounts = $.storageAccounts;
        this.storageAuthenticationType = $.storageAuthenticationType;
        this.tags = $.tags;
    }

    public static Builder builder() {
        return new Builder();
    }
    public static Builder builder(ServiceAccountState defaults) {
        return new Builder(defaults);
    }

    public static final class Builder {
        private ServiceAccountState $;

        public Builder() {
            $ = new ServiceAccountState();
        }

        public Builder(ServiceAccountState defaults) {
            $ = new ServiceAccountState(Objects.requireNonNull(defaults));
        }

        /**
         * @param encryption An `encryption` block as defined below.
         * 
         * @return builder
         * 
         */
        public Builder encryption(@Nullable Output<ServiceAccountEncryptionArgs> encryption) {
            $.encryption = encryption;
            return this;
        }

        /**
         * @param encryption An `encryption` block as defined below.
         * 
         * @return builder
         * 
         */
        public Builder encryption(ServiceAccountEncryptionArgs encryption) {
            return encryption(Output.of(encryption));
        }

        /**
         * @param identity An `identity` block as defined below.
         * 
         * @return builder
         * 
         */
        public Builder identity(@Nullable Output<ServiceAccountIdentityArgs> identity) {
            $.identity = identity;
            return this;
        }

        /**
         * @param identity An `identity` block as defined below.
         * 
         * @return builder
         * 
         */
        public Builder identity(ServiceAccountIdentityArgs identity) {
            return identity(Output.of(identity));
        }

        /**
         * @param keyDeliveryAccessControl A `key_delivery_access_control` block as defined below.
         * 
         * @return builder
         * 
         */
        public Builder keyDeliveryAccessControl(@Nullable Output<ServiceAccountKeyDeliveryAccessControlArgs> keyDeliveryAccessControl) {
            $.keyDeliveryAccessControl = keyDeliveryAccessControl;
            return this;
        }

        /**
         * @param keyDeliveryAccessControl A `key_delivery_access_control` block as defined below.
         * 
         * @return builder
         * 
         */
        public Builder keyDeliveryAccessControl(ServiceAccountKeyDeliveryAccessControlArgs keyDeliveryAccessControl) {
            return keyDeliveryAccessControl(Output.of(keyDeliveryAccessControl));
        }

        /**
         * @param location Specifies the supported Azure location where the resource exists. Changing this forces a new resource to be created.
         * 
         * @return builder
         * 
         */
        public Builder location(@Nullable Output<String> location) {
            $.location = location;
            return this;
        }

        /**
         * @param location Specifies the supported Azure location where the resource exists. Changing this forces a new resource to be created.
         * 
         * @return builder
         * 
         */
        public Builder location(String location) {
            return location(Output.of(location));
        }

        /**
         * @param name Specifies the name of the Media Services Account. Only lowercase Alphanumeric characters allowed. Changing this forces a new resource to be created.
         * 
         * @return builder
         * 
         */
        public Builder name(@Nullable Output<String> name) {
            $.name = name;
            return this;
        }

        /**
         * @param name Specifies the name of the Media Services Account. Only lowercase Alphanumeric characters allowed. Changing this forces a new resource to be created.
         * 
         * @return builder
         * 
         */
        public Builder name(String name) {
            return name(Output.of(name));
        }

        /**
         * @param publicNetworkAccessEnabled Whether public network access is allowed for this server. Defaults to `true`.
         * 
         * @return builder
         * 
         */
        public Builder publicNetworkAccessEnabled(@Nullable Output<Boolean> publicNetworkAccessEnabled) {
            $.publicNetworkAccessEnabled = publicNetworkAccessEnabled;
            return this;
        }

        /**
         * @param publicNetworkAccessEnabled Whether public network access is allowed for this server. Defaults to `true`.
         * 
         * @return builder
         * 
         */
        public Builder publicNetworkAccessEnabled(Boolean publicNetworkAccessEnabled) {
            return publicNetworkAccessEnabled(Output.of(publicNetworkAccessEnabled));
        }

        /**
         * @param resourceGroupName The name of the resource group in which to create the Media Services Account. Changing this forces a new resource to be created.
         * 
         * @return builder
         * 
         */
        public Builder resourceGroupName(@Nullable Output<String> resourceGroupName) {
            $.resourceGroupName = resourceGroupName;
            return this;
        }

        /**
         * @param resourceGroupName The name of the resource group in which to create the Media Services Account. Changing this forces a new resource to be created.
         * 
         * @return builder
         * 
         */
        public Builder resourceGroupName(String resourceGroupName) {
            return resourceGroupName(Output.of(resourceGroupName));
        }

        /**
         * @param storageAccounts One or more `storage_account` blocks as defined below.
         * 
         * @return builder
         * 
         */
        public Builder storageAccounts(@Nullable Output<List<ServiceAccountStorageAccountArgs>> storageAccounts) {
            $.storageAccounts = storageAccounts;
            return this;
        }

        /**
         * @param storageAccounts One or more `storage_account` blocks as defined below.
         * 
         * @return builder
         * 
         */
        public Builder storageAccounts(List<ServiceAccountStorageAccountArgs> storageAccounts) {
            return storageAccounts(Output.of(storageAccounts));
        }

        /**
         * @param storageAccounts One or more `storage_account` blocks as defined below.
         * 
         * @return builder
         * 
         */
        public Builder storageAccounts(ServiceAccountStorageAccountArgs... storageAccounts) {
            return storageAccounts(List.of(storageAccounts));
        }

        /**
         * @param storageAuthenticationType Specifies the storage authentication type. Possible value is `ManagedIdentity` or `System`.
         * 
         * @return builder
         * 
         */
        public Builder storageAuthenticationType(@Nullable Output<String> storageAuthenticationType) {
            $.storageAuthenticationType = storageAuthenticationType;
            return this;
        }

        /**
         * @param storageAuthenticationType Specifies the storage authentication type. Possible value is `ManagedIdentity` or `System`.
         * 
         * @return builder
         * 
         */
        public Builder storageAuthenticationType(String storageAuthenticationType) {
            return storageAuthenticationType(Output.of(storageAuthenticationType));
        }

        /**
         * @param tags A mapping of tags assigned to the resource.
         * 
         * @return builder
         * 
         */
        public Builder tags(@Nullable Output<Map<String,String>> tags) {
            $.tags = tags;
            return this;
        }

        /**
         * @param tags A mapping of tags assigned to the resource.
         * 
         * @return builder
         * 
         */
        public Builder tags(Map<String,String> tags) {
            return tags(Output.of(tags));
        }

        public ServiceAccountState build() {
            return $;
        }
    }

}
