Class CfnBucket.RoutingRuleConditionProperty.Builder
java.lang.Object
software.amazon.awscdk.services.s3.CfnBucket.RoutingRuleConditionProperty.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<CfnBucket.RoutingRuleConditionProperty>
- Enclosing interface:
CfnBucket.RoutingRuleConditionProperty
@Stability(Stable)
public static final class CfnBucket.RoutingRuleConditionProperty.Builder
extends Object
implements software.amazon.jsii.Builder<CfnBucket.RoutingRuleConditionProperty>
A builder for
CfnBucket.RoutingRuleConditionProperty
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionbuild()
Builds the configured instance.httpErrorCodeReturnedEquals
(String httpErrorCodeReturnedEquals) Sets the value ofCfnBucket.RoutingRuleConditionProperty.getHttpErrorCodeReturnedEquals()
keyPrefixEquals
(String keyPrefixEquals) Sets the value ofCfnBucket.RoutingRuleConditionProperty.getKeyPrefixEquals()
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
httpErrorCodeReturnedEquals
@Stability(Stable) public CfnBucket.RoutingRuleConditionProperty.Builder httpErrorCodeReturnedEquals(String httpErrorCodeReturnedEquals) Sets the value ofCfnBucket.RoutingRuleConditionProperty.getHttpErrorCodeReturnedEquals()
- Parameters:
httpErrorCodeReturnedEquals
- The HTTP error code when the redirect is applied. In the event of an error, if the error code equals this value, then the specified redirect is applied.Required when parent element
Condition
is specified and siblingKeyPrefixEquals
is not specified. If both are specified, then both must be true for the redirect to be applied.- Returns:
this
-
keyPrefixEquals
@Stability(Stable) public CfnBucket.RoutingRuleConditionProperty.Builder keyPrefixEquals(String keyPrefixEquals) Sets the value ofCfnBucket.RoutingRuleConditionProperty.getKeyPrefixEquals()
- Parameters:
keyPrefixEquals
- The object key name prefix when the redirect is applied. For example, to redirect requests forExamplePage.html
, the key prefix will beExamplePage.html
. To redirect request for all pages with the prefixdocs/
, the key prefix will be/docs
, which identifies all objects in the docs/ folder.Required when the parent element
Condition
is specified and siblingHttpErrorCodeReturnedEquals
is not specified. If both conditions are specified, both must be true for the redirect to be applied.- Returns:
this
-
build
Builds the configured instance.- Specified by:
build
in interfacesoftware.amazon.jsii.Builder<CfnBucket.RoutingRuleConditionProperty>
- Returns:
- a new instance of
CfnBucket.RoutingRuleConditionProperty
- Throws:
NullPointerException
- if any required attribute was not provided
-