Class ReEncryptInstructionFileRequest.Builder
- java.lang.Object
-
- software.amazon.encryption.s3.internal.ReEncryptInstructionFileRequest.Builder
-
- Enclosing class:
- ReEncryptInstructionFileRequest
public static class ReEncryptInstructionFileRequest.Builder extends Object
Builder for ReEncryptInstructionFileRequest.
-
-
Constructor Summary
Constructors Constructor Description Builder()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ReEncryptInstructionFileRequest.Builder
bucket(String bucket)
Sets the S3 bucket name for the re-encryption of instruction file.ReEncryptInstructionFileRequest
build()
Validates and builds the ReEncryptInstructionFileRequest according to the configuration options passed to the Builder object.ReEncryptInstructionFileRequest.Builder
enforceRotation(boolean enforceRotation)
Sets whether to enforce rotation for the re-encrypted instruction file.ReEncryptInstructionFileRequest.Builder
instructionFileSuffix(String instructionFileSuffix)
Sets a custom instruction file suffix for the re-encrypted instruction file.ReEncryptInstructionFileRequest.Builder
key(String key)
Sets the S3 object key for the re-encryption of instruction file.ReEncryptInstructionFileRequest.Builder
newKeyring(RawKeyring newKeyring)
Sets the new keyring for re-encryption of instruction file.
-
-
-
Method Detail
-
bucket
public ReEncryptInstructionFileRequest.Builder bucket(String bucket)
Sets the S3 bucket name for the re-encryption of instruction file.- Parameters:
bucket
- the S3 bucket name- Returns:
- a reference to this object so that method calls can be chained together.
-
key
public ReEncryptInstructionFileRequest.Builder key(String key)
Sets the S3 object key for the re-encryption of instruction file.- Parameters:
key
- the S3 object key- Returns:
- a reference to this object so that method calls can be chained together.
-
newKeyring
public ReEncryptInstructionFileRequest.Builder newKeyring(RawKeyring newKeyring)
Sets the new keyring for re-encryption of instruction file.- Parameters:
newKeyring
- the new keyring for re-encryption- Returns:
- a reference to this object so that method calls can be chained together.
-
instructionFileSuffix
public ReEncryptInstructionFileRequest.Builder instructionFileSuffix(String instructionFileSuffix)
Sets a custom instruction file suffix for the re-encrypted instruction file. For AES keyrings, only the default instruction file suffix is allowed. For RSA keyrings, both the default and custom instruction file suffixes are allowed. Note: The "." prefix is automatically added to the suffix- Parameters:
instructionFileSuffix
- the instruction file suffix- Returns:
- a reference to this object so that method calls can be chained together.
-
enforceRotation
public ReEncryptInstructionFileRequest.Builder enforceRotation(boolean enforceRotation)
Sets whether to enforce rotation for the re-encrypted instruction file. When enabled, the client will attempt to decrypt the re-encrypted instruction file with the old key material and throw an exception when decryption succeeds. This is a stronger level of validation that the wrapping key has been rotated than the standard assertion that the materials descriptions are different.- Parameters:
enforceRotation
- whether to enforce rotation- Returns:
- a reference to this object so that method calls can be chained together.
-
build
public ReEncryptInstructionFileRequest build()
Validates and builds the ReEncryptInstructionFileRequest according to the configuration options passed to the Builder object.- Returns:
- an instance of the ReEncryptInstructionFileRequest
-
-