Enum BucketAccessControl
- All Implemented Interfaces:
Serializable
,Comparable<BucketAccessControl>
,java.lang.constant.Constable
@Generated(value="jsii-pacmak/1.104.0 (build e79254c)",
date="2024-11-22T02:24:08.803Z")
@Stability(Stable)
public enum BucketAccessControl
extends Enum<BucketAccessControl>
Default bucket access control types.
Example:
Bucket websiteBucket = Bucket.Builder.create(this, "WebsiteBucket") .websiteIndexDocument("index.html") .publicReadAccess(true) .build(); BucketDeployment.Builder.create(this, "DeployWebsite") .sources(List.of(Source.asset("./website-dist"))) .destinationBucket(websiteBucket) .destinationKeyPrefix("web/static") // optional prefix in destination bucket .metadata(Map.of("A", "1", "b", "2")) // user-defined metadata // system-defined metadata .contentType("text/html") .contentLanguage("en") .storageClass(StorageClass.INTELLIGENT_TIERING) .serverSideEncryption(ServerSideEncryption.AES_256) .cacheControl(List.of(CacheControl.setPublic(), CacheControl.maxAge(Duration.hours(1)))) .accessControl(BucketAccessControl.BUCKET_OWNER_FULL_CONTROL) .build();
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum ConstantDescriptionOwner gets FULL_CONTROL.Owner gets FULL_CONTROL.Both the object owner and the bucket owner get FULL_CONTROL over the object.Object owner gets FULL_CONTROL.The LogDelivery group gets WRITE and READ_ACP permissions on the bucket.Owner gets FULL_CONTROL.Owner gets FULL_CONTROL.Owner gets FULL_CONTROL. -
Method Summary
Modifier and TypeMethodDescriptionstatic BucketAccessControl
Returns the enum constant of this type with the specified name.static BucketAccessControl[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
Enum Constant Details
-
PRIVATE
Owner gets FULL_CONTROL.No one else has access rights.
-
PUBLIC_READ
Owner gets FULL_CONTROL.The AllUsers group gets READ access.
-
PUBLIC_READ_WRITE
Owner gets FULL_CONTROL.The AllUsers group gets READ and WRITE access. Granting this on a bucket is generally not recommended.
-
AUTHENTICATED_READ
Owner gets FULL_CONTROL.The AuthenticatedUsers group gets READ access.
-
LOG_DELIVERY_WRITE
The LogDelivery group gets WRITE and READ_ACP permissions on the bucket.- See Also:
-
BUCKET_OWNER_READ
Object owner gets FULL_CONTROL.Bucket owner gets READ access. If you specify this canned ACL when creating a bucket, Amazon S3 ignores it.
-
BUCKET_OWNER_FULL_CONTROL
Both the object owner and the bucket owner get FULL_CONTROL over the object.If you specify this canned ACL when creating a bucket, Amazon S3 ignores it.
-
AWS_EXEC_READ
Owner gets FULL_CONTROL.Amazon EC2 gets READ access to GET an Amazon Machine Image (AMI) bundle from Amazon S3.
-
-
Method Details
-
values
Returns an array containing the constants of this enum type, in the order they are declared.- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is null
-