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

com.pulumi.azurenative.authorization.ManagementLockAtResourceLevelArgs Maven / Gradle / Ivy

The 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.authorization;

import com.pulumi.azurenative.authorization.enums.LockLevel;
import com.pulumi.azurenative.authorization.inputs.ManagementLockOwnerArgs;
import com.pulumi.core.Either;
import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
import com.pulumi.exceptions.MissingRequiredPropertyException;
import java.lang.String;
import java.util.List;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;


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

    public static final ManagementLockAtResourceLevelArgs Empty = new ManagementLockAtResourceLevelArgs();

    /**
     * The level of the lock. Possible values are: NotSpecified, CanNotDelete, ReadOnly. CanNotDelete means authorized users are able to read and modify the resources, but not delete. ReadOnly means authorized users can only read from a resource, but they can't modify or delete it.
     * 
     */
    @Import(name="level", required=true)
    private Output> level;

    /**
     * @return The level of the lock. Possible values are: NotSpecified, CanNotDelete, ReadOnly. CanNotDelete means authorized users are able to read and modify the resources, but not delete. ReadOnly means authorized users can only read from a resource, but they can't modify or delete it.
     * 
     */
    public Output> level() {
        return this.level;
    }

    /**
     * The name of lock. The lock name can be a maximum of 260 characters. It cannot contain <, > %, &, :, \, ?, /, or any control characters.
     * 
     */
    @Import(name="lockName")
    private @Nullable Output lockName;

    /**
     * @return The name of lock. The lock name can be a maximum of 260 characters. It cannot contain <, > %, &, :, \, ?, /, or any control characters.
     * 
     */
    public Optional> lockName() {
        return Optional.ofNullable(this.lockName);
    }

    /**
     * Notes about the lock. Maximum of 512 characters.
     * 
     */
    @Import(name="notes")
    private @Nullable Output notes;

    /**
     * @return Notes about the lock. Maximum of 512 characters.
     * 
     */
    public Optional> notes() {
        return Optional.ofNullable(this.notes);
    }

    /**
     * The owners of the lock.
     * 
     */
    @Import(name="owners")
    private @Nullable Output> owners;

    /**
     * @return The owners of the lock.
     * 
     */
    public Optional>> owners() {
        return Optional.ofNullable(this.owners);
    }

    /**
     * The parent resource identity.
     * 
     */
    @Import(name="parentResourcePath", required=true)
    private Output parentResourcePath;

    /**
     * @return The parent resource identity.
     * 
     */
    public Output parentResourcePath() {
        return this.parentResourcePath;
    }

    /**
     * The name of the resource group containing the resource to lock.
     * 
     */
    @Import(name="resourceGroupName", required=true)
    private Output resourceGroupName;

    /**
     * @return The name of the resource group containing the resource to lock.
     * 
     */
    public Output resourceGroupName() {
        return this.resourceGroupName;
    }

    /**
     * The name of the resource to lock.
     * 
     */
    @Import(name="resourceName", required=true)
    private Output resourceName;

    /**
     * @return The name of the resource to lock.
     * 
     */
    public Output resourceName() {
        return this.resourceName;
    }

    /**
     * The resource provider namespace of the resource to lock.
     * 
     */
    @Import(name="resourceProviderNamespace", required=true)
    private Output resourceProviderNamespace;

    /**
     * @return The resource provider namespace of the resource to lock.
     * 
     */
    public Output resourceProviderNamespace() {
        return this.resourceProviderNamespace;
    }

    /**
     * The resource type of the resource to lock.
     * 
     */
    @Import(name="resourceType", required=true)
    private Output resourceType;

    /**
     * @return The resource type of the resource to lock.
     * 
     */
    public Output resourceType() {
        return this.resourceType;
    }

    private ManagementLockAtResourceLevelArgs() {}

    private ManagementLockAtResourceLevelArgs(ManagementLockAtResourceLevelArgs $) {
        this.level = $.level;
        this.lockName = $.lockName;
        this.notes = $.notes;
        this.owners = $.owners;
        this.parentResourcePath = $.parentResourcePath;
        this.resourceGroupName = $.resourceGroupName;
        this.resourceName = $.resourceName;
        this.resourceProviderNamespace = $.resourceProviderNamespace;
        this.resourceType = $.resourceType;
    }

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

    public static final class Builder {
        private ManagementLockAtResourceLevelArgs $;

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

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

        /**
         * @param level The level of the lock. Possible values are: NotSpecified, CanNotDelete, ReadOnly. CanNotDelete means authorized users are able to read and modify the resources, but not delete. ReadOnly means authorized users can only read from a resource, but they can't modify or delete it.
         * 
         * @return builder
         * 
         */
        public Builder level(Output> level) {
            $.level = level;
            return this;
        }

        /**
         * @param level The level of the lock. Possible values are: NotSpecified, CanNotDelete, ReadOnly. CanNotDelete means authorized users are able to read and modify the resources, but not delete. ReadOnly means authorized users can only read from a resource, but they can't modify or delete it.
         * 
         * @return builder
         * 
         */
        public Builder level(Either level) {
            return level(Output.of(level));
        }

        /**
         * @param level The level of the lock. Possible values are: NotSpecified, CanNotDelete, ReadOnly. CanNotDelete means authorized users are able to read and modify the resources, but not delete. ReadOnly means authorized users can only read from a resource, but they can't modify or delete it.
         * 
         * @return builder
         * 
         */
        public Builder level(String level) {
            return level(Either.ofLeft(level));
        }

        /**
         * @param level The level of the lock. Possible values are: NotSpecified, CanNotDelete, ReadOnly. CanNotDelete means authorized users are able to read and modify the resources, but not delete. ReadOnly means authorized users can only read from a resource, but they can't modify or delete it.
         * 
         * @return builder
         * 
         */
        public Builder level(LockLevel level) {
            return level(Either.ofRight(level));
        }

        /**
         * @param lockName The name of lock. The lock name can be a maximum of 260 characters. It cannot contain <, > %, &, :, \, ?, /, or any control characters.
         * 
         * @return builder
         * 
         */
        public Builder lockName(@Nullable Output lockName) {
            $.lockName = lockName;
            return this;
        }

        /**
         * @param lockName The name of lock. The lock name can be a maximum of 260 characters. It cannot contain <, > %, &, :, \, ?, /, or any control characters.
         * 
         * @return builder
         * 
         */
        public Builder lockName(String lockName) {
            return lockName(Output.of(lockName));
        }

        /**
         * @param notes Notes about the lock. Maximum of 512 characters.
         * 
         * @return builder
         * 
         */
        public Builder notes(@Nullable Output notes) {
            $.notes = notes;
            return this;
        }

        /**
         * @param notes Notes about the lock. Maximum of 512 characters.
         * 
         * @return builder
         * 
         */
        public Builder notes(String notes) {
            return notes(Output.of(notes));
        }

        /**
         * @param owners The owners of the lock.
         * 
         * @return builder
         * 
         */
        public Builder owners(@Nullable Output> owners) {
            $.owners = owners;
            return this;
        }

        /**
         * @param owners The owners of the lock.
         * 
         * @return builder
         * 
         */
        public Builder owners(List owners) {
            return owners(Output.of(owners));
        }

        /**
         * @param owners The owners of the lock.
         * 
         * @return builder
         * 
         */
        public Builder owners(ManagementLockOwnerArgs... owners) {
            return owners(List.of(owners));
        }

        /**
         * @param parentResourcePath The parent resource identity.
         * 
         * @return builder
         * 
         */
        public Builder parentResourcePath(Output parentResourcePath) {
            $.parentResourcePath = parentResourcePath;
            return this;
        }

        /**
         * @param parentResourcePath The parent resource identity.
         * 
         * @return builder
         * 
         */
        public Builder parentResourcePath(String parentResourcePath) {
            return parentResourcePath(Output.of(parentResourcePath));
        }

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

        /**
         * @param resourceGroupName The name of the resource group containing the resource to lock.
         * 
         * @return builder
         * 
         */
        public Builder resourceGroupName(String resourceGroupName) {
            return resourceGroupName(Output.of(resourceGroupName));
        }

        /**
         * @param resourceName The name of the resource to lock.
         * 
         * @return builder
         * 
         */
        public Builder resourceName(Output resourceName) {
            $.resourceName = resourceName;
            return this;
        }

        /**
         * @param resourceName The name of the resource to lock.
         * 
         * @return builder
         * 
         */
        public Builder resourceName(String resourceName) {
            return resourceName(Output.of(resourceName));
        }

        /**
         * @param resourceProviderNamespace The resource provider namespace of the resource to lock.
         * 
         * @return builder
         * 
         */
        public Builder resourceProviderNamespace(Output resourceProviderNamespace) {
            $.resourceProviderNamespace = resourceProviderNamespace;
            return this;
        }

        /**
         * @param resourceProviderNamespace The resource provider namespace of the resource to lock.
         * 
         * @return builder
         * 
         */
        public Builder resourceProviderNamespace(String resourceProviderNamespace) {
            return resourceProviderNamespace(Output.of(resourceProviderNamespace));
        }

        /**
         * @param resourceType The resource type of the resource to lock.
         * 
         * @return builder
         * 
         */
        public Builder resourceType(Output resourceType) {
            $.resourceType = resourceType;
            return this;
        }

        /**
         * @param resourceType The resource type of the resource to lock.
         * 
         * @return builder
         * 
         */
        public Builder resourceType(String resourceType) {
            return resourceType(Output.of(resourceType));
        }

        public ManagementLockAtResourceLevelArgs build() {
            if ($.level == null) {
                throw new MissingRequiredPropertyException("ManagementLockAtResourceLevelArgs", "level");
            }
            if ($.parentResourcePath == null) {
                throw new MissingRequiredPropertyException("ManagementLockAtResourceLevelArgs", "parentResourcePath");
            }
            if ($.resourceGroupName == null) {
                throw new MissingRequiredPropertyException("ManagementLockAtResourceLevelArgs", "resourceGroupName");
            }
            if ($.resourceName == null) {
                throw new MissingRequiredPropertyException("ManagementLockAtResourceLevelArgs", "resourceName");
            }
            if ($.resourceProviderNamespace == null) {
                throw new MissingRequiredPropertyException("ManagementLockAtResourceLevelArgs", "resourceProviderNamespace");
            }
            if ($.resourceType == null) {
                throw new MissingRequiredPropertyException("ManagementLockAtResourceLevelArgs", "resourceType");
            }
            return $;
        }
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy