public AmazonS3EncryptionClientV2Builder withEncryptionMaterialsProvider(
            EncryptionMaterialsProvider encryptionMaterialsProvider) {
        setEncryptionMaterialsProvider(encryptionMaterialsProvider);
        return this;
    }
Sets the encryption materials to be used to encrypt and decrypt data.
<p>
<b>Note: </b> If a non-KMS encryption materials provider is used, an internal KMS client will still be created by default.
See {@link #withKmsClient(AWSKMS)} for more information.

@param encryptionMaterialsProvider A provider for the encryption materials to be used to encrypt and decrypt data.
@return this object for method chaining
aws-java-sdk-s3/src/main/java/com/amazonaws/services/s3/AmazonS3EncryptionClientV2Builder.java