
com.pulumi.azurenative.authorization.outputs.RoleManagementPolicyEnablementRuleResponse Maven / Gradle / Ivy
// *** 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.outputs;
import com.pulumi.azurenative.authorization.outputs.RoleManagementPolicyRuleTargetResponse;
import com.pulumi.core.annotations.CustomType;
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;
@CustomType
public final class RoleManagementPolicyEnablementRuleResponse {
/**
* @return The list of enabled rules.
*
*/
private @Nullable List enabledRules;
/**
* @return The id of the rule.
*
*/
private @Nullable String id;
/**
* @return The type of rule
* Expected value is 'RoleManagementPolicyEnablementRule'.
*
*/
private String ruleType;
/**
* @return The target of the current rule.
*
*/
private @Nullable RoleManagementPolicyRuleTargetResponse target;
private RoleManagementPolicyEnablementRuleResponse() {}
/**
* @return The list of enabled rules.
*
*/
public List enabledRules() {
return this.enabledRules == null ? List.of() : this.enabledRules;
}
/**
* @return The id of the rule.
*
*/
public Optional id() {
return Optional.ofNullable(this.id);
}
/**
* @return The type of rule
* Expected value is 'RoleManagementPolicyEnablementRule'.
*
*/
public String ruleType() {
return this.ruleType;
}
/**
* @return The target of the current rule.
*
*/
public Optional target() {
return Optional.ofNullable(this.target);
}
public static Builder builder() {
return new Builder();
}
public static Builder builder(RoleManagementPolicyEnablementRuleResponse defaults) {
return new Builder(defaults);
}
@CustomType.Builder
public static final class Builder {
private @Nullable List enabledRules;
private @Nullable String id;
private String ruleType;
private @Nullable RoleManagementPolicyRuleTargetResponse target;
public Builder() {}
public Builder(RoleManagementPolicyEnablementRuleResponse defaults) {
Objects.requireNonNull(defaults);
this.enabledRules = defaults.enabledRules;
this.id = defaults.id;
this.ruleType = defaults.ruleType;
this.target = defaults.target;
}
@CustomType.Setter
public Builder enabledRules(@Nullable List enabledRules) {
this.enabledRules = enabledRules;
return this;
}
public Builder enabledRules(String... enabledRules) {
return enabledRules(List.of(enabledRules));
}
@CustomType.Setter
public Builder id(@Nullable String id) {
this.id = id;
return this;
}
@CustomType.Setter
public Builder ruleType(String ruleType) {
if (ruleType == null) {
throw new MissingRequiredPropertyException("RoleManagementPolicyEnablementRuleResponse", "ruleType");
}
this.ruleType = ruleType;
return this;
}
@CustomType.Setter
public Builder target(@Nullable RoleManagementPolicyRuleTargetResponse target) {
this.target = target;
return this;
}
public RoleManagementPolicyEnablementRuleResponse build() {
final var _resultValue = new RoleManagementPolicyEnablementRuleResponse();
_resultValue.enabledRules = enabledRules;
_resultValue.id = id;
_resultValue.ruleType = ruleType;
_resultValue.target = target;
return _resultValue;
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy