com.pulumi.azurenative.network.outputs.NetworkRuleConditionResponse Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of azure-native Show documentation
Show all versions of azure-native Show documentation
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.network.outputs;
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 NetworkRuleConditionResponse {
/**
* @return Description of the rule condition.
*
*/
private @Nullable String description;
/**
* @return List of destination IP addresses or Service Tags.
*
*/
private @Nullable List destinationAddresses;
/**
* @return List of destination IpGroups for this rule.
*
*/
private @Nullable List destinationIpGroups;
/**
* @return List of destination ports.
*
*/
private @Nullable List destinationPorts;
/**
* @return Array of FirewallPolicyRuleConditionNetworkProtocols.
*
*/
private @Nullable List ipProtocols;
/**
* @return Name of the rule condition.
*
*/
private @Nullable String name;
/**
* @return Rule Condition Type.
* Expected value is 'NetworkRuleCondition'.
*
*/
private String ruleConditionType;
/**
* @return List of source IP addresses for this rule.
*
*/
private @Nullable List sourceAddresses;
/**
* @return List of source IpGroups for this rule.
*
*/
private @Nullable List sourceIpGroups;
private NetworkRuleConditionResponse() {}
/**
* @return Description of the rule condition.
*
*/
public Optional description() {
return Optional.ofNullable(this.description);
}
/**
* @return List of destination IP addresses or Service Tags.
*
*/
public List destinationAddresses() {
return this.destinationAddresses == null ? List.of() : this.destinationAddresses;
}
/**
* @return List of destination IpGroups for this rule.
*
*/
public List destinationIpGroups() {
return this.destinationIpGroups == null ? List.of() : this.destinationIpGroups;
}
/**
* @return List of destination ports.
*
*/
public List destinationPorts() {
return this.destinationPorts == null ? List.of() : this.destinationPorts;
}
/**
* @return Array of FirewallPolicyRuleConditionNetworkProtocols.
*
*/
public List ipProtocols() {
return this.ipProtocols == null ? List.of() : this.ipProtocols;
}
/**
* @return Name of the rule condition.
*
*/
public Optional name() {
return Optional.ofNullable(this.name);
}
/**
* @return Rule Condition Type.
* Expected value is 'NetworkRuleCondition'.
*
*/
public String ruleConditionType() {
return this.ruleConditionType;
}
/**
* @return List of source IP addresses for this rule.
*
*/
public List sourceAddresses() {
return this.sourceAddresses == null ? List.of() : this.sourceAddresses;
}
/**
* @return List of source IpGroups for this rule.
*
*/
public List sourceIpGroups() {
return this.sourceIpGroups == null ? List.of() : this.sourceIpGroups;
}
public static Builder builder() {
return new Builder();
}
public static Builder builder(NetworkRuleConditionResponse defaults) {
return new Builder(defaults);
}
@CustomType.Builder
public static final class Builder {
private @Nullable String description;
private @Nullable List destinationAddresses;
private @Nullable List destinationIpGroups;
private @Nullable List destinationPorts;
private @Nullable List ipProtocols;
private @Nullable String name;
private String ruleConditionType;
private @Nullable List sourceAddresses;
private @Nullable List sourceIpGroups;
public Builder() {}
public Builder(NetworkRuleConditionResponse defaults) {
Objects.requireNonNull(defaults);
this.description = defaults.description;
this.destinationAddresses = defaults.destinationAddresses;
this.destinationIpGroups = defaults.destinationIpGroups;
this.destinationPorts = defaults.destinationPorts;
this.ipProtocols = defaults.ipProtocols;
this.name = defaults.name;
this.ruleConditionType = defaults.ruleConditionType;
this.sourceAddresses = defaults.sourceAddresses;
this.sourceIpGroups = defaults.sourceIpGroups;
}
@CustomType.Setter
public Builder description(@Nullable String description) {
this.description = description;
return this;
}
@CustomType.Setter
public Builder destinationAddresses(@Nullable List destinationAddresses) {
this.destinationAddresses = destinationAddresses;
return this;
}
public Builder destinationAddresses(String... destinationAddresses) {
return destinationAddresses(List.of(destinationAddresses));
}
@CustomType.Setter
public Builder destinationIpGroups(@Nullable List destinationIpGroups) {
this.destinationIpGroups = destinationIpGroups;
return this;
}
public Builder destinationIpGroups(String... destinationIpGroups) {
return destinationIpGroups(List.of(destinationIpGroups));
}
@CustomType.Setter
public Builder destinationPorts(@Nullable List destinationPorts) {
this.destinationPorts = destinationPorts;
return this;
}
public Builder destinationPorts(String... destinationPorts) {
return destinationPorts(List.of(destinationPorts));
}
@CustomType.Setter
public Builder ipProtocols(@Nullable List ipProtocols) {
this.ipProtocols = ipProtocols;
return this;
}
public Builder ipProtocols(String... ipProtocols) {
return ipProtocols(List.of(ipProtocols));
}
@CustomType.Setter
public Builder name(@Nullable String name) {
this.name = name;
return this;
}
@CustomType.Setter
public Builder ruleConditionType(String ruleConditionType) {
if (ruleConditionType == null) {
throw new MissingRequiredPropertyException("NetworkRuleConditionResponse", "ruleConditionType");
}
this.ruleConditionType = ruleConditionType;
return this;
}
@CustomType.Setter
public Builder sourceAddresses(@Nullable List sourceAddresses) {
this.sourceAddresses = sourceAddresses;
return this;
}
public Builder sourceAddresses(String... sourceAddresses) {
return sourceAddresses(List.of(sourceAddresses));
}
@CustomType.Setter
public Builder sourceIpGroups(@Nullable List sourceIpGroups) {
this.sourceIpGroups = sourceIpGroups;
return this;
}
public Builder sourceIpGroups(String... sourceIpGroups) {
return sourceIpGroups(List.of(sourceIpGroups));
}
public NetworkRuleConditionResponse build() {
final var _resultValue = new NetworkRuleConditionResponse();
_resultValue.description = description;
_resultValue.destinationAddresses = destinationAddresses;
_resultValue.destinationIpGroups = destinationIpGroups;
_resultValue.destinationPorts = destinationPorts;
_resultValue.ipProtocols = ipProtocols;
_resultValue.name = name;
_resultValue.ruleConditionType = ruleConditionType;
_resultValue.sourceAddresses = sourceAddresses;
_resultValue.sourceIpGroups = sourceIpGroups;
return _resultValue;
}
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy