Skip to content

Commit

Permalink
change super class for EncryptionException to CommonException
Browse files Browse the repository at this point in the history
  • Loading branch information
skublik committed Mar 8, 2024
1 parent cd8c938 commit 3b9b13b
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 6 deletions.
Original file line number Diff line number Diff line change
@@ -1,24 +1,36 @@
/*
* Copyright (c) 2010-2013 Evolveum and contributors
* Copyright (c) 2010-2024 Evolveum and contributors
*
* This work is dual-licensed under the Apache License 2.0
* and European Union Public License. See LICENSE file for details.
*/
package com.evolveum.midpoint.prism.crypto;

public class EncryptionException extends Exception {
import com.evolveum.midpoint.util.LocalizableMessage;
import com.evolveum.midpoint.util.exception.CommonException;

public class EncryptionException extends CommonException {

private static final long serialVersionUID = 8289563205061329615L;

public EncryptionException(String message) {
super(message);
}

public EncryptionException(String message, Throwable throwable) {
super(message, throwable);
public EncryptionException(LocalizableMessage userFriendlyMessage) {
super(userFriendlyMessage);
}

public EncryptionException(Throwable cause) {
super(cause);
}

public EncryptionException(String message, Throwable cause) {
super(message, cause);
}

public EncryptionException(Throwable throwable) {
super(throwable);
@Override
public String getErrorTypeMessage() {
return "Encryption error";
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -80,4 +80,8 @@ public ExternalDataType clone() {
public void accept(JaxbVisitor visitor) {
visitor.visit(this);
}

public boolean isEmpty() {
return key == null && provider == null;
}
}

0 comments on commit 3b9b13b

Please sign in to comment.