public static final class BucketAttributes.Builder
extends java.lang.Object
BucketAttributes
Constructor and Description |
---|
Builder() |
public BucketAttributes.Builder account(java.lang.String account)
BucketAttributes.getAccount()
account
- The account this existing bucket belongs to.this
public BucketAttributes.Builder bucketArn(java.lang.String bucketArn)
BucketAttributes.getBucketArn()
bucketArn
- The ARN of the bucket.
At least one of bucketArn or bucketName must be
defined in order to initialize a bucket ref.this
public BucketAttributes.Builder bucketDomainName(java.lang.String bucketDomainName)
BucketAttributes.getBucketDomainName()
bucketDomainName
- The domain name of the bucket.this
public BucketAttributes.Builder bucketDualStackDomainName(java.lang.String bucketDualStackDomainName)
BucketAttributes.getBucketDualStackDomainName()
bucketDualStackDomainName
- The IPv6 DNS name of the specified bucket.this
public BucketAttributes.Builder bucketName(java.lang.String bucketName)
BucketAttributes.getBucketName()
bucketName
- The name of the bucket.
If the underlying value of ARN is a string, the
name will be parsed from the ARN. Otherwise, the name is optional, but
some features that require the bucket name such as auto-creating a bucket
policy, won't work.this
public BucketAttributes.Builder bucketRegionalDomainName(java.lang.String bucketRegionalDomainName)
BucketAttributes.getBucketRegionalDomainName()
bucketRegionalDomainName
- The regional domain name of the specified bucket.this
public BucketAttributes.Builder bucketWebsiteNewUrlFormat(java.lang.Boolean bucketWebsiteNewUrlFormat)
BucketAttributes.getBucketWebsiteNewUrlFormat()
bucketWebsiteNewUrlFormat
- The format of the website URL of the bucket.
This should be true for
regions launched since 2014.this
public BucketAttributes.Builder bucketWebsiteUrl(java.lang.String bucketWebsiteUrl)
BucketAttributes.getBucketWebsiteUrl()
bucketWebsiteUrl
- The website URL of the bucket (if static web hosting is enabled).this
public BucketAttributes.Builder encryptionKey(IKey encryptionKey)
BucketAttributes.getEncryptionKey()
encryptionKey
- the value to be set.this
public BucketAttributes.Builder isWebsite(java.lang.Boolean isWebsite)
BucketAttributes.getIsWebsite()
isWebsite
- If this bucket has been configured for static website hosting.this
public BucketAttributes.Builder notificationsHandlerRole(IRole notificationsHandlerRole)
BucketAttributes.getNotificationsHandlerRole()
notificationsHandlerRole
- The role to be used by the notifications handler.this
public BucketAttributes.Builder region(java.lang.String region)
BucketAttributes.getRegion()
region
- The region this existing bucket is in.this
public BucketAttributes build()
BucketAttributes
java.lang.NullPointerException
- if any required attribute was not provided