public enum CipherTransformation extends Enum<CipherTransformation>
CipherAlgorithm
, CipherMode
and CipherPadding
). It also includes the default scheme Absio uses: DEFAULT
.Enum Constant and Description |
---|
AES_CTR_NOPADDING
This represents the "AES/CTR/NoPadding" transformation.
|
Modifier and Type | Field and Description |
---|---|
static CipherTransformation |
DEFAULT
This is the default transformation that Absio uses:
AES_CTR_NOPADDING |
Modifier and Type | Method and Description |
---|---|
com.absio.crypto.cipher.CipherTransformation.CipherAlgorithm |
getAlgorithm()
Get the
CipherAlgorithm of the transformation. |
int |
getBlockSize()
Get the block size of the algorithm.
|
static CipherTransformation |
getByIndex(long index)
Gets the transformation by index.
|
int |
getIndex()
Get the index of the transformation.
|
com.absio.crypto.cipher.CipherTransformation.CipherMode |
getMode()
Get the
CipherMode of the transformation. |
com.absio.crypto.cipher.CipherTransformation.CipherPadding |
getPadding()
Get the
CipherPadding of the transformation. |
String |
getTransformation()
Get the transformation in the string format the JCE understands: "algorithm/mode/padding".
|
static CipherTransformation |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static CipherTransformation[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final CipherTransformation AES_CTR_NOPADDING
public static final CipherTransformation DEFAULT
AES_CTR_NOPADDING
public static CipherTransformation[] values()
for (CipherTransformation c : CipherTransformation.values()) System.out.println(c);
public static CipherTransformation valueOf(String name)
name
- the name of the enum constant to be returned.IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is nullpublic static CipherTransformation getByIndex(long index) throws NoSuchAlgorithmException
index
- the index of the transformation to getNoSuchAlgorithmException
- thrown if no transformation exists with the given indexpublic com.absio.crypto.cipher.CipherTransformation.CipherAlgorithm getAlgorithm()
CipherAlgorithm
of the transformation.CipherAlgorithm
of the transformationpublic int getBlockSize()
public int getIndex()
public com.absio.crypto.cipher.CipherTransformation.CipherMode getMode()
CipherMode
of the transformation.CipherMode
of the transformationpublic com.absio.crypto.cipher.CipherTransformation.CipherPadding getPadding()
CipherPadding
of the transformation.CipherPadding
of the transformationpublic String getTransformation()
Copyright © 2021. All rights reserved.