
com.pulumi.azurenative.azurestackhci.outputs.GetSecurityRuleResult 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.azurestackhci.outputs;
import com.pulumi.azurenative.azurestackhci.outputs.ExtendedLocationResponse;
import com.pulumi.azurenative.azurestackhci.outputs.SystemDataResponse;
import com.pulumi.core.annotations.CustomType;
import com.pulumi.exceptions.MissingRequiredPropertyException;
import java.lang.Integer;
import java.lang.String;
import java.util.List;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;
@CustomType
public final class GetSecurityRuleResult {
/**
* @return The network traffic is allowed or denied.
*
*/
private String access;
/**
* @return A description for this rule. Restricted to 140 chars.
*
*/
private @Nullable String description;
/**
* @return The destination address prefixes. CIDR or destination IP ranges.
*
*/
private @Nullable List destinationAddressPrefixes;
/**
* @return The destination port ranges. Integer or range between 0 and 65535. Asterisk '*' can also be used to match all ports.
*
*/
private @Nullable List destinationPortRanges;
/**
* @return The direction of the rule. The direction specifies if rule will be evaluated on incoming or outgoing traffic.
*
*/
private String direction;
/**
* @return The extendedLocation of the resource.
*
*/
private @Nullable ExtendedLocationResponse extendedLocation;
/**
* @return Fully qualified resource ID for the resource. E.g. "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}"
*
*/
private String id;
/**
* @return The name of the resource
*
*/
private String name;
/**
* @return The priority of the rule. The value can be between 100 and 4096. The priority number must be unique for each rule in the collection. The lower the priority number, the higher the priority of the rule.
*
*/
private Integer priority;
/**
* @return Network protocol this rule applies to.
*
*/
private String protocol;
/**
* @return Provisioning state of the SR
*
*/
private String provisioningState;
/**
* @return The CIDR or source IP ranges.
*
*/
private @Nullable List sourceAddressPrefixes;
/**
* @return The source port ranges. Integer or range between 0 and 65535. Asterisk '*' can also be used to match all ports.
*
*/
private @Nullable List sourcePortRanges;
/**
* @return Azure Resource Manager metadata containing createdBy and modifiedBy information.
*
*/
private SystemDataResponse systemData;
/**
* @return The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
*
*/
private String type;
private GetSecurityRuleResult() {}
/**
* @return The network traffic is allowed or denied.
*
*/
public String access() {
return this.access;
}
/**
* @return A description for this rule. Restricted to 140 chars.
*
*/
public Optional description() {
return Optional.ofNullable(this.description);
}
/**
* @return The destination address prefixes. CIDR or destination IP ranges.
*
*/
public List destinationAddressPrefixes() {
return this.destinationAddressPrefixes == null ? List.of() : this.destinationAddressPrefixes;
}
/**
* @return The destination port ranges. Integer or range between 0 and 65535. Asterisk '*' can also be used to match all ports.
*
*/
public List destinationPortRanges() {
return this.destinationPortRanges == null ? List.of() : this.destinationPortRanges;
}
/**
* @return The direction of the rule. The direction specifies if rule will be evaluated on incoming or outgoing traffic.
*
*/
public String direction() {
return this.direction;
}
/**
* @return The extendedLocation of the resource.
*
*/
public Optional extendedLocation() {
return Optional.ofNullable(this.extendedLocation);
}
/**
* @return Fully qualified resource ID for the resource. E.g. "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}"
*
*/
public String id() {
return this.id;
}
/**
* @return The name of the resource
*
*/
public String name() {
return this.name;
}
/**
* @return The priority of the rule. The value can be between 100 and 4096. The priority number must be unique for each rule in the collection. The lower the priority number, the higher the priority of the rule.
*
*/
public Integer priority() {
return this.priority;
}
/**
* @return Network protocol this rule applies to.
*
*/
public String protocol() {
return this.protocol;
}
/**
* @return Provisioning state of the SR
*
*/
public String provisioningState() {
return this.provisioningState;
}
/**
* @return The CIDR or source IP ranges.
*
*/
public List sourceAddressPrefixes() {
return this.sourceAddressPrefixes == null ? List.of() : this.sourceAddressPrefixes;
}
/**
* @return The source port ranges. Integer or range between 0 and 65535. Asterisk '*' can also be used to match all ports.
*
*/
public List sourcePortRanges() {
return this.sourcePortRanges == null ? List.of() : this.sourcePortRanges;
}
/**
* @return Azure Resource Manager metadata containing createdBy and modifiedBy information.
*
*/
public SystemDataResponse systemData() {
return this.systemData;
}
/**
* @return The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
*
*/
public String type() {
return this.type;
}
public static Builder builder() {
return new Builder();
}
public static Builder builder(GetSecurityRuleResult defaults) {
return new Builder(defaults);
}
@CustomType.Builder
public static final class Builder {
private String access;
private @Nullable String description;
private @Nullable List destinationAddressPrefixes;
private @Nullable List destinationPortRanges;
private String direction;
private @Nullable ExtendedLocationResponse extendedLocation;
private String id;
private String name;
private Integer priority;
private String protocol;
private String provisioningState;
private @Nullable List sourceAddressPrefixes;
private @Nullable List sourcePortRanges;
private SystemDataResponse systemData;
private String type;
public Builder() {}
public Builder(GetSecurityRuleResult defaults) {
Objects.requireNonNull(defaults);
this.access = defaults.access;
this.description = defaults.description;
this.destinationAddressPrefixes = defaults.destinationAddressPrefixes;
this.destinationPortRanges = defaults.destinationPortRanges;
this.direction = defaults.direction;
this.extendedLocation = defaults.extendedLocation;
this.id = defaults.id;
this.name = defaults.name;
this.priority = defaults.priority;
this.protocol = defaults.protocol;
this.provisioningState = defaults.provisioningState;
this.sourceAddressPrefixes = defaults.sourceAddressPrefixes;
this.sourcePortRanges = defaults.sourcePortRanges;
this.systemData = defaults.systemData;
this.type = defaults.type;
}
@CustomType.Setter
public Builder access(String access) {
if (access == null) {
throw new MissingRequiredPropertyException("GetSecurityRuleResult", "access");
}
this.access = access;
return this;
}
@CustomType.Setter
public Builder description(@Nullable String description) {
this.description = description;
return this;
}
@CustomType.Setter
public Builder destinationAddressPrefixes(@Nullable List destinationAddressPrefixes) {
this.destinationAddressPrefixes = destinationAddressPrefixes;
return this;
}
public Builder destinationAddressPrefixes(String... destinationAddressPrefixes) {
return destinationAddressPrefixes(List.of(destinationAddressPrefixes));
}
@CustomType.Setter
public Builder destinationPortRanges(@Nullable List destinationPortRanges) {
this.destinationPortRanges = destinationPortRanges;
return this;
}
public Builder destinationPortRanges(String... destinationPortRanges) {
return destinationPortRanges(List.of(destinationPortRanges));
}
@CustomType.Setter
public Builder direction(String direction) {
if (direction == null) {
throw new MissingRequiredPropertyException("GetSecurityRuleResult", "direction");
}
this.direction = direction;
return this;
}
@CustomType.Setter
public Builder extendedLocation(@Nullable ExtendedLocationResponse extendedLocation) {
this.extendedLocation = extendedLocation;
return this;
}
@CustomType.Setter
public Builder id(String id) {
if (id == null) {
throw new MissingRequiredPropertyException("GetSecurityRuleResult", "id");
}
this.id = id;
return this;
}
@CustomType.Setter
public Builder name(String name) {
if (name == null) {
throw new MissingRequiredPropertyException("GetSecurityRuleResult", "name");
}
this.name = name;
return this;
}
@CustomType.Setter
public Builder priority(Integer priority) {
if (priority == null) {
throw new MissingRequiredPropertyException("GetSecurityRuleResult", "priority");
}
this.priority = priority;
return this;
}
@CustomType.Setter
public Builder protocol(String protocol) {
if (protocol == null) {
throw new MissingRequiredPropertyException("GetSecurityRuleResult", "protocol");
}
this.protocol = protocol;
return this;
}
@CustomType.Setter
public Builder provisioningState(String provisioningState) {
if (provisioningState == null) {
throw new MissingRequiredPropertyException("GetSecurityRuleResult", "provisioningState");
}
this.provisioningState = provisioningState;
return this;
}
@CustomType.Setter
public Builder sourceAddressPrefixes(@Nullable List sourceAddressPrefixes) {
this.sourceAddressPrefixes = sourceAddressPrefixes;
return this;
}
public Builder sourceAddressPrefixes(String... sourceAddressPrefixes) {
return sourceAddressPrefixes(List.of(sourceAddressPrefixes));
}
@CustomType.Setter
public Builder sourcePortRanges(@Nullable List sourcePortRanges) {
this.sourcePortRanges = sourcePortRanges;
return this;
}
public Builder sourcePortRanges(String... sourcePortRanges) {
return sourcePortRanges(List.of(sourcePortRanges));
}
@CustomType.Setter
public Builder systemData(SystemDataResponse systemData) {
if (systemData == null) {
throw new MissingRequiredPropertyException("GetSecurityRuleResult", "systemData");
}
this.systemData = systemData;
return this;
}
@CustomType.Setter
public Builder type(String type) {
if (type == null) {
throw new MissingRequiredPropertyException("GetSecurityRuleResult", "type");
}
this.type = type;
return this;
}
public GetSecurityRuleResult build() {
final var _resultValue = new GetSecurityRuleResult();
_resultValue.access = access;
_resultValue.description = description;
_resultValue.destinationAddressPrefixes = destinationAddressPrefixes;
_resultValue.destinationPortRanges = destinationPortRanges;
_resultValue.direction = direction;
_resultValue.extendedLocation = extendedLocation;
_resultValue.id = id;
_resultValue.name = name;
_resultValue.priority = priority;
_resultValue.protocol = protocol;
_resultValue.provisioningState = provisioningState;
_resultValue.sourceAddressPrefixes = sourceAddressPrefixes;
_resultValue.sourcePortRanges = sourcePortRanges;
_resultValue.systemData = systemData;
_resultValue.type = type;
return _resultValue;
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy