com.pulumi.aws.wafv2.outputs.RuleGroupRuleStatementGeoMatchStatement Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of aws Show documentation
Show all versions of aws Show documentation
A Pulumi package for creating and managing Amazon Web Services (AWS) cloud 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.aws.wafv2.outputs;
import com.pulumi.aws.wafv2.outputs.RuleGroupRuleStatementGeoMatchStatementForwardedIpConfig;
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 RuleGroupRuleStatementGeoMatchStatement {
/**
* @return An array of two-character country codes, for example, [ "US", "CN" ], from the alpha-2 country ISO codes of the `ISO 3166` international standard. See the [documentation](https://docs.aws.amazon.com/waf/latest/APIReference/API_GeoMatchStatement.html) for valid values.
*
*/
private List countryCodes;
/**
* @return The configuration for inspecting IP addresses in an HTTP header that you specify, instead of using the IP address that's reported by the web request origin. See Forwarded IP Config below for details.
*
*/
private @Nullable RuleGroupRuleStatementGeoMatchStatementForwardedIpConfig forwardedIpConfig;
private RuleGroupRuleStatementGeoMatchStatement() {}
/**
* @return An array of two-character country codes, for example, [ "US", "CN" ], from the alpha-2 country ISO codes of the `ISO 3166` international standard. See the [documentation](https://docs.aws.amazon.com/waf/latest/APIReference/API_GeoMatchStatement.html) for valid values.
*
*/
public List countryCodes() {
return this.countryCodes;
}
/**
* @return The configuration for inspecting IP addresses in an HTTP header that you specify, instead of using the IP address that's reported by the web request origin. See Forwarded IP Config below for details.
*
*/
public Optional forwardedIpConfig() {
return Optional.ofNullable(this.forwardedIpConfig);
}
public static Builder builder() {
return new Builder();
}
public static Builder builder(RuleGroupRuleStatementGeoMatchStatement defaults) {
return new Builder(defaults);
}
@CustomType.Builder
public static final class Builder {
private List countryCodes;
private @Nullable RuleGroupRuleStatementGeoMatchStatementForwardedIpConfig forwardedIpConfig;
public Builder() {}
public Builder(RuleGroupRuleStatementGeoMatchStatement defaults) {
Objects.requireNonNull(defaults);
this.countryCodes = defaults.countryCodes;
this.forwardedIpConfig = defaults.forwardedIpConfig;
}
@CustomType.Setter
public Builder countryCodes(List countryCodes) {
if (countryCodes == null) {
throw new MissingRequiredPropertyException("RuleGroupRuleStatementGeoMatchStatement", "countryCodes");
}
this.countryCodes = countryCodes;
return this;
}
public Builder countryCodes(String... countryCodes) {
return countryCodes(List.of(countryCodes));
}
@CustomType.Setter
public Builder forwardedIpConfig(@Nullable RuleGroupRuleStatementGeoMatchStatementForwardedIpConfig forwardedIpConfig) {
this.forwardedIpConfig = forwardedIpConfig;
return this;
}
public RuleGroupRuleStatementGeoMatchStatement build() {
final var _resultValue = new RuleGroupRuleStatementGeoMatchStatement();
_resultValue.countryCodes = countryCodes;
_resultValue.forwardedIpConfig = forwardedIpConfig;
return _resultValue;
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy