Package org.cyclos.model.utils
Class ActionConfirmationHelper
- java.lang.Object
-
- org.cyclos.model.utils.ActionConfirmationHelper
-
public class ActionConfirmationHelper extends Object
Helper class for actions requiring confirmation using device / password confirmations.
-
-
Constructor Summary
Constructors Constructor Description ActionConfirmationHelper()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static MessageKeygetMessageKey(EnumMessageKeyResolver<ActionConfirmationStatus> baseKey, PasswordInputDTO input)Returns the key to be used for the message shown in conjunction with the password input field in an action confirmation.static booleanisCanConfirm(PasswordInputDTO input, ActionConfirmationMode mode)Returns true if the action can be confirmed with a password or device in case the given mode is null.
-
-
-
Method Detail
-
getMessageKey
public static MessageKey getMessageKey(EnumMessageKeyResolver<ActionConfirmationStatus> baseKey, PasswordInputDTO input)
Returns the key to be used for the message shown in conjunction with the password input field in an action confirmation.
-
isCanConfirm
public static boolean isCanConfirm(PasswordInputDTO input, ActionConfirmationMode mode)
Returns true if the action can be confirmed with a password or device in case the given mode is null. Otherwise, with the specified mode. If the given input is null then it means not required confirmation at all then it'll return true.
-
-