Key instead.@Immutable @Deprecated public interface TinkKey
TinkKey represents how Tink views individual keys. In contrast, KeysetHandle only
provides access to a Keyset, which represents multiple keys.
A TinkKey contains the data associated to a type of key and provides ways of getting
that data. The TinkKey interface does not specify how the key data is represented nor how
it provides access to the data.
| Modifier and Type | Method and Description |
|---|---|
KeyTemplate |
getKeyTemplate()
Deprecated.
A
TinkKey should know the KeyTemplate from which it was generated,
which in turn specifies the cryptographic algorithm in which the TinkKey should
be used. |
boolean |
hasSecret()
Deprecated.
Returns true if the key contains secret key material, and false otherwise.
|
boolean hasSecret()
KeyTemplate getKeyTemplate()
TinkKey should know the KeyTemplate from which it was generated,
which in turn specifies the cryptographic algorithm in which the TinkKey should
be used.
Throws UnsupportedOperationException to help ease rollout until it is possible to easily
find the KeyTemplate associated to a key described in protoKeyTemplate used to generate the key.UnsupportedOperationException - if the TinkKey does not yet support returning
its KeyTemplate