Class BlockPublicAccessOptions.Builder
java.lang.Object
software.amazon.awscdk.services.s3.BlockPublicAccessOptions.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<BlockPublicAccessOptions>
- Enclosing interface:
BlockPublicAccessOptions
@Stability(Stable)
public static final class BlockPublicAccessOptions.Builder
extends Object
implements software.amazon.jsii.Builder<BlockPublicAccessOptions>
A builder for
BlockPublicAccessOptions
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionblockPublicAcls
(Boolean blockPublicAcls) Sets the value ofBlockPublicAccessOptions.getBlockPublicAcls()
blockPublicPolicy
(Boolean blockPublicPolicy) Sets the value ofBlockPublicAccessOptions.getBlockPublicPolicy()
build()
Builds the configured instance.ignorePublicAcls
(Boolean ignorePublicAcls) Sets the value ofBlockPublicAccessOptions.getIgnorePublicAcls()
restrictPublicBuckets
(Boolean restrictPublicBuckets) Sets the value ofBlockPublicAccessOptions.getRestrictPublicBuckets()
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
blockPublicAcls
Sets the value ofBlockPublicAccessOptions.getBlockPublicAcls()
- Parameters:
blockPublicAcls
- Whether to block public ACLs.- Returns:
this
-
blockPublicPolicy
@Stability(Stable) public BlockPublicAccessOptions.Builder blockPublicPolicy(Boolean blockPublicPolicy) Sets the value ofBlockPublicAccessOptions.getBlockPublicPolicy()
- Parameters:
blockPublicPolicy
- Whether to block public policy.- Returns:
this
-
ignorePublicAcls
@Stability(Stable) public BlockPublicAccessOptions.Builder ignorePublicAcls(Boolean ignorePublicAcls) Sets the value ofBlockPublicAccessOptions.getIgnorePublicAcls()
- Parameters:
ignorePublicAcls
- Whether to ignore public ACLs.- Returns:
this
-
restrictPublicBuckets
@Stability(Stable) public BlockPublicAccessOptions.Builder restrictPublicBuckets(Boolean restrictPublicBuckets) Sets the value ofBlockPublicAccessOptions.getRestrictPublicBuckets()
- Parameters:
restrictPublicBuckets
- Whether to restrict public access.- Returns:
this
-
build
Builds the configured instance.- Specified by:
build
in interfacesoftware.amazon.jsii.Builder<BlockPublicAccessOptions>
- Returns:
- a new instance of
BlockPublicAccessOptions
- Throws:
NullPointerException
- if any required attribute was not provided
-