mirror of
https://github.com/pgpainless/pgpainless.git
synced 2024-09-28 18:49:56 +02:00
EncryptionOptions: Change return val of overrideEncryptionAlgorithm to EncryptionOptions
This commit is contained in:
parent
963a8170da
commit
3fd929916d
|
@ -273,11 +273,12 @@ public class EncryptionOptions {
|
|||
*
|
||||
* @param encryptionAlgorithm encryption algorithm override
|
||||
*/
|
||||
public void overrideEncryptionAlgorithm(SymmetricKeyAlgorithm encryptionAlgorithm) {
|
||||
public EncryptionOptions overrideEncryptionAlgorithm(SymmetricKeyAlgorithm encryptionAlgorithm) {
|
||||
if (encryptionAlgorithm == SymmetricKeyAlgorithm.NULL) {
|
||||
throw new IllegalArgumentException("Plaintext encryption can only be used to denote unencrypted secret keys.");
|
||||
}
|
||||
this.encryptionAlgorithmOverride = encryptionAlgorithm;
|
||||
return this;
|
||||
}
|
||||
|
||||
public interface EncryptionKeySelector {
|
||||
|
|
Loading…
Reference in a new issue