Package org.apache.orc.impl.reader
Class ReaderEncryptionKey
java.lang.Object
org.apache.orc.impl.reader.ReaderEncryptionKey
- All Implemented Interfaces:
Comparable<EncryptionKey>
,EncryptionKey
This tracks the keys for reading encrypted columns.
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic enum
Store the state of whether we've tried to decrypt a local key using this key or not. -
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionint
compareTo
(@NotNull EncryptionKey other) boolean
The encryption algorithm for this key.The columns that are encrypted with this key.The name of the key.int
The version of the key.getState()
int
hashCode()
boolean
Is the key available to this user?void
void
toString()
-
Constructor Details
-
ReaderEncryptionKey
-
-
Method Details
-
getKeyName
Description copied from interface:EncryptionKey
The name of the key.- Specified by:
getKeyName
in interfaceEncryptionKey
- Returns:
- the name
-
getKeyVersion
public int getKeyVersion()Description copied from interface:EncryptionKey
The version of the key.- Specified by:
getKeyVersion
in interfaceEncryptionKey
- Returns:
- the version, which for most KeyProviders start at 0.
-
getAlgorithm
Description copied from interface:EncryptionKey
The encryption algorithm for this key.- Specified by:
getAlgorithm
in interfaceEncryptionKey
- Returns:
- the encryption algorithm
-
getEncryptionRoots
Description copied from interface:EncryptionKey
The columns that are encrypted with this key.- Specified by:
getEncryptionRoots
in interfaceEncryptionKey
- Returns:
- the list of columns
-
getMetadata
-
getState
-
setFailure
public void setFailure() -
setSuccess
public void setSuccess() -
equals
-
hashCode
public int hashCode() -
compareTo
- Specified by:
compareTo
in interfaceComparable<EncryptionKey>
-
toString
-
isAvailable
public boolean isAvailable()Description copied from interface:EncryptionKey
Is the key available to this user?- Specified by:
isAvailable
in interfaceEncryptionKey
- Returns:
- true if the key is available
-