All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.pulumi.azurenative.cache.AccessPolicyArgs Maven / Gradle / Ivy

There is a newer version: 2.78.0
Show newest version
// *** 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.azurenative.cache;

import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
import com.pulumi.exceptions.MissingRequiredPropertyException;
import java.lang.String;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;


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

    public static final AccessPolicyArgs Empty = new AccessPolicyArgs();

    /**
     * The name of the access policy that is being added to the Redis cache.
     * 
     */
    @Import(name="accessPolicyName")
    private @Nullable Output accessPolicyName;

    /**
     * @return The name of the access policy that is being added to the Redis cache.
     * 
     */
    public Optional> accessPolicyName() {
        return Optional.ofNullable(this.accessPolicyName);
    }

    /**
     * The name of the Redis cache.
     * 
     */
    @Import(name="cacheName", required=true)
    private Output cacheName;

    /**
     * @return The name of the Redis cache.
     * 
     */
    public Output cacheName() {
        return this.cacheName;
    }

    /**
     * Permissions for the access policy. Learn how to configure permissions at https://aka.ms/redis/AADPreRequisites
     * 
     */
    @Import(name="permissions", required=true)
    private Output permissions;

    /**
     * @return Permissions for the access policy. Learn how to configure permissions at https://aka.ms/redis/AADPreRequisites
     * 
     */
    public Output permissions() {
        return this.permissions;
    }

    /**
     * The name of the resource group. The name is case insensitive.
     * 
     */
    @Import(name="resourceGroupName", required=true)
    private Output resourceGroupName;

    /**
     * @return The name of the resource group. The name is case insensitive.
     * 
     */
    public Output resourceGroupName() {
        return this.resourceGroupName;
    }

    private AccessPolicyArgs() {}

    private AccessPolicyArgs(AccessPolicyArgs $) {
        this.accessPolicyName = $.accessPolicyName;
        this.cacheName = $.cacheName;
        this.permissions = $.permissions;
        this.resourceGroupName = $.resourceGroupName;
    }

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

    public static final class Builder {
        private AccessPolicyArgs $;

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

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

        /**
         * @param accessPolicyName The name of the access policy that is being added to the Redis cache.
         * 
         * @return builder
         * 
         */
        public Builder accessPolicyName(@Nullable Output accessPolicyName) {
            $.accessPolicyName = accessPolicyName;
            return this;
        }

        /**
         * @param accessPolicyName The name of the access policy that is being added to the Redis cache.
         * 
         * @return builder
         * 
         */
        public Builder accessPolicyName(String accessPolicyName) {
            return accessPolicyName(Output.of(accessPolicyName));
        }

        /**
         * @param cacheName The name of the Redis cache.
         * 
         * @return builder
         * 
         */
        public Builder cacheName(Output cacheName) {
            $.cacheName = cacheName;
            return this;
        }

        /**
         * @param cacheName The name of the Redis cache.
         * 
         * @return builder
         * 
         */
        public Builder cacheName(String cacheName) {
            return cacheName(Output.of(cacheName));
        }

        /**
         * @param permissions Permissions for the access policy. Learn how to configure permissions at https://aka.ms/redis/AADPreRequisites
         * 
         * @return builder
         * 
         */
        public Builder permissions(Output permissions) {
            $.permissions = permissions;
            return this;
        }

        /**
         * @param permissions Permissions for the access policy. Learn how to configure permissions at https://aka.ms/redis/AADPreRequisites
         * 
         * @return builder
         * 
         */
        public Builder permissions(String permissions) {
            return permissions(Output.of(permissions));
        }

        /**
         * @param resourceGroupName The name of the resource group. The name is case insensitive.
         * 
         * @return builder
         * 
         */
        public Builder resourceGroupName(Output resourceGroupName) {
            $.resourceGroupName = resourceGroupName;
            return this;
        }

        /**
         * @param resourceGroupName The name of the resource group. The name is case insensitive.
         * 
         * @return builder
         * 
         */
        public Builder resourceGroupName(String resourceGroupName) {
            return resourceGroupName(Output.of(resourceGroupName));
        }

        public AccessPolicyArgs build() {
            if ($.cacheName == null) {
                throw new MissingRequiredPropertyException("AccessPolicyArgs", "cacheName");
            }
            if ($.permissions == null) {
                throw new MissingRequiredPropertyException("AccessPolicyArgs", "permissions");
            }
            if ($.resourceGroupName == null) {
                throw new MissingRequiredPropertyException("AccessPolicyArgs", "resourceGroupName");
            }
            return $;
        }
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy