public abstract class SimpleRecoveryPolicy extends java.lang.Object implements RecoveryPolicy
RecoveryPolicy that supports removing data
and throwing exceptions.| Modifier and Type | Class and Description |
|---|---|
static class |
SimpleRecoveryPolicy.Default
Default implementation
|
| Constructor and Description |
|---|
SimpleRecoveryPolicy() |
| Modifier and Type | Method and Description |
|---|---|
void |
handleBrokenContent(EncryptionProtocolException e,
java.lang.String keyHash,
java.lang.String base64Encrypted,
boolean userPasswordUsed,
ArmadilloSharedPreferences sharedPreferences)
When a value cannot be decrypted, this method will be called
|
public void handleBrokenContent(EncryptionProtocolException e, java.lang.String keyHash, java.lang.String base64Encrypted, boolean userPasswordUsed, ArmadilloSharedPreferences sharedPreferences) throws SecureSharedPreferenceCryptoException
RecoveryPolicyhandleBrokenContent in interface RecoveryPolicye - thrown exceptionkeyHash - hash of the key that was calledbase64Encrypted - encrypted data in base64 encodinguserPasswordUsed - if a user password was used to decrypt the storagesharedPreferences - currently used shared preference (be aware if you modify)SecureSharedPreferenceCryptoException - if you want to throw an exception, use or wrap in this typ