public static final class KmsMasterKeyProvider.Builder extends Object implements Cloneable
| Constructor and Description |
|---|
Builder() |
| Modifier and Type | Method and Description |
|---|---|
KmsMasterKeyProvider |
build()
Builds the master key provider.
|
KmsMasterKeyProvider.Builder |
clone() |
KmsMasterKeyProvider.Builder |
withClientBuilder(com.amazonaws.services.kms.AWSKMSClientBuilder builder)
Configures the
KmsMasterKeyProvider to use settings from this AWSKMSClientBuilder to
configure KMS clients. |
KmsMasterKeyProvider.Builder |
withCredentials(com.amazonaws.auth.AWSCredentials credentials)
Configures the
KmsMasterKeyProvider to use specific credentials. |
KmsMasterKeyProvider.Builder |
withCredentials(com.amazonaws.auth.AWSCredentialsProvider credentialsProvider)
Configures the
KmsMasterKeyProvider to use specific credentials. |
KmsMasterKeyProvider.Builder |
withCustomClientFactory(KmsMasterKeyProvider.RegionalClientSupplier regionalClientSupplier)
Provides a custom factory function that will vend KMS clients.
|
KmsMasterKeyProvider.Builder |
withDefaultRegion(String defaultRegion)
Sets the default region.
|
KmsMasterKeyProvider.Builder |
withKeysForEncryption(List<String> keyIds)
Adds key ID(s) to the list of keys to use on encryption.
|
KmsMasterKeyProvider.Builder |
withKeysForEncryption(String... keyIds)
Adds key ID(s) to the list of keys to use on encryption.
|
public KmsMasterKeyProvider.Builder clone()
public KmsMasterKeyProvider.Builder withKeysForEncryption(String... keyIds)
keyIds - public KmsMasterKeyProvider.Builder withKeysForEncryption(List<String> keyIds)
keyIds - public KmsMasterKeyProvider.Builder withDefaultRegion(String defaultRegion)
MasterKeyProvider.getMasterKey(String) that are not full ARNs, but are instead bare key IDs or
aliases.
If the default region is not specified, only full key ARNs will be usable.defaultRegion - The default region to use.public KmsMasterKeyProvider.Builder withCustomClientFactory(KmsMasterKeyProvider.RegionalClientSupplier regionalClientSupplier)
withCredentials(AWSCredentialsProvider) or
withClientBuilder(AWSKMSClientBuilder); if you try to use these in combination, an
IllegalStateException will be thrown.regionalClientSupplier - public KmsMasterKeyProvider.Builder withCredentials(com.amazonaws.auth.AWSCredentialsProvider credentialsProvider)
KmsMasterKeyProvider to use specific credentials. If a builder was previously set,
this will override whatever credentials it set.credentialsProvider - public KmsMasterKeyProvider.Builder withCredentials(com.amazonaws.auth.AWSCredentials credentials)
KmsMasterKeyProvider to use specific credentials. If a builder was previously set,
this will override whatever credentials it set.credentials - public KmsMasterKeyProvider.Builder withClientBuilder(com.amazonaws.services.kms.AWSKMSClientBuilder builder)
KmsMasterKeyProvider to use settings from this AWSKMSClientBuilder to
configure KMS clients. Note that the region set on this builder will be ignored, but all other settings
will be propagated into the regional clients.
This method will overwrite any credentials set using withCredentials(AWSCredentialsProvider).builder - public KmsMasterKeyProvider build()
Copyright © 2018. All rights reserved.