com.pulumi.azure.hpc.outputs.CacheDefaultAccessPolicy 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.azure.hpc.outputs;
import com.pulumi.azure.hpc.outputs.CacheDefaultAccessPolicyAccessRule;
import com.pulumi.core.annotations.CustomType;
import com.pulumi.exceptions.MissingRequiredPropertyException;
import java.util.List;
import java.util.Objects;
@CustomType
public final class CacheDefaultAccessPolicy {
/**
* @return One or more `access_rule` blocks (up to three) as defined above.
*
*/
private List accessRules;
private CacheDefaultAccessPolicy() {}
/**
* @return One or more `access_rule` blocks (up to three) as defined above.
*
*/
public List accessRules() {
return this.accessRules;
}
public static Builder builder() {
return new Builder();
}
public static Builder builder(CacheDefaultAccessPolicy defaults) {
return new Builder(defaults);
}
@CustomType.Builder
public static final class Builder {
private List accessRules;
public Builder() {}
public Builder(CacheDefaultAccessPolicy defaults) {
Objects.requireNonNull(defaults);
this.accessRules = defaults.accessRules;
}
@CustomType.Setter
public Builder accessRules(List accessRules) {
if (accessRules == null) {
throw new MissingRequiredPropertyException("CacheDefaultAccessPolicy", "accessRules");
}
this.accessRules = accessRules;
return this;
}
public Builder accessRules(CacheDefaultAccessPolicyAccessRule... accessRules) {
return accessRules(List.of(accessRules));
}
public CacheDefaultAccessPolicy build() {
final var _resultValue = new CacheDefaultAccessPolicy();
_resultValue.accessRules = accessRules;
return _resultValue;
}
}
}