Interface KeyEntity
-
- All Known Implementing Classes:
DefaultKeyEntity
public interface KeyEntityInterface to describe a key entity managed by theJpaCryptoEngine. The module provides a default implementationDefaultKeyEntity, but this is specified as an interface so applications may easily use a different implementation, with their own JPA annotations.Implementations are required to have a zero-arg constructor (which is generally required for JPA entities). The
JpaCryptoEnginewill create new instances by invoking this constructor and then invoking the setters.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description StringgetKeyId()Read accessor to thekeyId.StringgetSecretKeyBase64()Read accessor tosecretKeyBase64.voidsetKeyId(String keyId)Write accessor to thekeyId.voidsetSecretKeyBase64(String secretKeyBase64)Write accessor tosecretKeyBase64.
-
-
-
Method Detail
-
getKeyId
String getKeyId()
Read accessor to thekeyId. This is the primary key of the entity.- Returns:
- the current value
-
setKeyId
void setKeyId(String keyId)
Write accessor to thekeyId. This is the primary key of the entity.- Parameters:
keyId- the new value
-
getSecretKeyBase64
String getSecretKeyBase64()
Read accessor tosecretKeyBase64. This is a representation of the secret key bytes in Base64-form.- Returns:
- the current value
-
setSecretKeyBase64
void setSecretKeyBase64(String secretKeyBase64)
Write accessor tosecretKeyBase64. This is a representation of the secret key bytes in Base64-form.- Parameters:
secretKeyBase64- the new value
-
-