
com.pulumi.aws.s3.outputs.BucketV2ServerSideEncryptionConfigurationRuleApplyServerSideEncryptionByDefault Maven / Gradle / Ivy
// *** 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.s3.outputs;
import com.pulumi.core.annotations.CustomType;
import com.pulumi.exceptions.MissingRequiredPropertyException;
import java.lang.String;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;
@CustomType
public final class BucketV2ServerSideEncryptionConfigurationRuleApplyServerSideEncryptionByDefault {
/**
* @return AWS KMS master key ID used for the SSE-KMS encryption. This can only be used when you set the value of `sse_algorithm` as `aws:kms`. The default `aws/s3` AWS KMS master key is used if this element is absent while the `sse_algorithm` is `aws:kms`.
*
*/
private @Nullable String kmsMasterKeyId;
/**
* @return Server-side encryption algorithm to use. Valid values are `AES256` and `aws:kms`
*
*/
private String sseAlgorithm;
private BucketV2ServerSideEncryptionConfigurationRuleApplyServerSideEncryptionByDefault() {}
/**
* @return AWS KMS master key ID used for the SSE-KMS encryption. This can only be used when you set the value of `sse_algorithm` as `aws:kms`. The default `aws/s3` AWS KMS master key is used if this element is absent while the `sse_algorithm` is `aws:kms`.
*
*/
public Optional kmsMasterKeyId() {
return Optional.ofNullable(this.kmsMasterKeyId);
}
/**
* @return Server-side encryption algorithm to use. Valid values are `AES256` and `aws:kms`
*
*/
public String sseAlgorithm() {
return this.sseAlgorithm;
}
public static Builder builder() {
return new Builder();
}
public static Builder builder(BucketV2ServerSideEncryptionConfigurationRuleApplyServerSideEncryptionByDefault defaults) {
return new Builder(defaults);
}
@CustomType.Builder
public static final class Builder {
private @Nullable String kmsMasterKeyId;
private String sseAlgorithm;
public Builder() {}
public Builder(BucketV2ServerSideEncryptionConfigurationRuleApplyServerSideEncryptionByDefault defaults) {
Objects.requireNonNull(defaults);
this.kmsMasterKeyId = defaults.kmsMasterKeyId;
this.sseAlgorithm = defaults.sseAlgorithm;
}
@CustomType.Setter
public Builder kmsMasterKeyId(@Nullable String kmsMasterKeyId) {
this.kmsMasterKeyId = kmsMasterKeyId;
return this;
}
@CustomType.Setter
public Builder sseAlgorithm(String sseAlgorithm) {
if (sseAlgorithm == null) {
throw new MissingRequiredPropertyException("BucketV2ServerSideEncryptionConfigurationRuleApplyServerSideEncryptionByDefault", "sseAlgorithm");
}
this.sseAlgorithm = sseAlgorithm;
return this;
}
public BucketV2ServerSideEncryptionConfigurationRuleApplyServerSideEncryptionByDefault build() {
final var _resultValue = new BucketV2ServerSideEncryptionConfigurationRuleApplyServerSideEncryptionByDefault();
_resultValue.kmsMasterKeyId = kmsMasterKeyId;
_resultValue.sseAlgorithm = sseAlgorithm;
return _resultValue;
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy