Please wait. This can take some minutes ...
Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance.
Project price only 1 $
You can buy this project and download/modify it how often you want.
com.pulumi.azurenative.authorization.ManagementLockByScopeArgs Maven / Gradle / Ivy
Go to download
A native Pulumi package for creating and managing Azure resources.
// *** 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 ManagementLockByScopeArgs extends com.pulumi.resources.ResourceArgs {
public static final ManagementLockByScopeArgs Empty = new ManagementLockByScopeArgs();
/**
* 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.
*
*/
@Import(name="lockName")
private @Nullable Output lockName;
/**
* @return The name of lock.
*
*/
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 scope for the lock. When providing a scope for the assignment, use '/subscriptions/{subscriptionId}' for subscriptions, '/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}' for resource groups, and '/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{parentResourcePathIfPresent}/{resourceType}/{resourceName}' for resources.
*
*/
@Import(name="scope", required=true)
private Output scope;
/**
* @return The scope for the lock. When providing a scope for the assignment, use '/subscriptions/{subscriptionId}' for subscriptions, '/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}' for resource groups, and '/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{parentResourcePathIfPresent}/{resourceType}/{resourceName}' for resources.
*
*/
public Output scope() {
return this.scope;
}
private ManagementLockByScopeArgs() {}
private ManagementLockByScopeArgs(ManagementLockByScopeArgs $) {
this.level = $.level;
this.lockName = $.lockName;
this.notes = $.notes;
this.owners = $.owners;
this.scope = $.scope;
}
public static Builder builder() {
return new Builder();
}
public static Builder builder(ManagementLockByScopeArgs defaults) {
return new Builder(defaults);
}
public static final class Builder {
private ManagementLockByScopeArgs $;
public Builder() {
$ = new ManagementLockByScopeArgs();
}
public Builder(ManagementLockByScopeArgs defaults) {
$ = new ManagementLockByScopeArgs(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.
*
* @return builder
*
*/
public Builder lockName(@Nullable Output lockName) {
$.lockName = lockName;
return this;
}
/**
* @param lockName The name of lock.
*
* @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 scope The scope for the lock. When providing a scope for the assignment, use '/subscriptions/{subscriptionId}' for subscriptions, '/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}' for resource groups, and '/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{parentResourcePathIfPresent}/{resourceType}/{resourceName}' for resources.
*
* @return builder
*
*/
public Builder scope(Output scope) {
$.scope = scope;
return this;
}
/**
* @param scope The scope for the lock. When providing a scope for the assignment, use '/subscriptions/{subscriptionId}' for subscriptions, '/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}' for resource groups, and '/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{parentResourcePathIfPresent}/{resourceType}/{resourceName}' for resources.
*
* @return builder
*
*/
public Builder scope(String scope) {
return scope(Output.of(scope));
}
public ManagementLockByScopeArgs build() {
if ($.level == null) {
throw new MissingRequiredPropertyException("ManagementLockByScopeArgs", "level");
}
if ($.scope == null) {
throw new MissingRequiredPropertyException("ManagementLockByScopeArgs", "scope");
}
return $;
}
}
}