public final class ErrorSmartkey extends Object implements Smartkey
to further investigate the error| Modifier and Type | Field and Description |
|---|---|
MetaClientException |
cause |
| Constructor and Description |
|---|
ErrorSmartkey(MetaClientException cause) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
canDecrypt() |
boolean |
canEncrypt() |
boolean |
canManage() |
List<Feature> |
getFeatures() |
SecretKey |
getKey() |
SecretKey |
getKeyForDecryption(int revision) |
String |
getName()
Useful for displaying in UIs.
|
List<KnownUser> |
getParticipants() |
int |
getRevision() |
String |
getUrn()
The URN for a Smartkey will never change.
|
String |
toString() |
@Nonnull public final MetaClientException cause
public ErrorSmartkey(MetaClientException cause)
@Nonnull public String getName()
Smartkey@Nonnull public String getUrn()
Smartkey@Nonnull public SecretKey getKey() throws MetaClientException
getKey in interface SmartkeySmartkey.getRevision()MetaClientException - if not allowed to encrypt using this keySmartkey.canEncrypt()public int getRevision()
getRevision in interface Smartkey@Nonnull public List<Feature> getFeatures()
getFeatures in interface Smartkey@Nonnull public List<KnownUser> getParticipants()
getParticipants in interface Smartkeypublic boolean canManage()
public boolean canEncrypt()
canEncrypt in interface Smartkeytrue if this user is allowed to encrypt using this smartkey. If
false, attempts to retrieve the encryption key will throw an exception.public boolean canDecrypt()
canDecrypt in interface Smartkeytrue if this user is allowed to decrypt using this smartkey. If
false, attempts to retrieve the decryption key with throw an exception.public SecretKey getKeyForDecryption(int revision) throws MetaClientException
getKeyForDecryption in interface Smartkeynull if no key is available for the given revisionMetaClientException - if this key is not allowed to be used for decryptionSmartkey.canDecrypt()