java.lang.Object
io.github.astrapi69.crypt.data.algorithm.CryptoAlgorithm
- All Implemented Interfaces:
io.github.astrapi69.crypt.api.algorithm.Algorithm
public class CryptoAlgorithm
extends Object
implements io.github.astrapi69.crypt.api.algorithm.Algorithm
The class
CryptoAlgorithm
provides factory method for create an algorithm from string for
encryption or decryption.-
Field Summary
Fields inherited from interface io.github.astrapi69.crypt.api.algorithm.Algorithm
UNKNOWN_ALGORITHM_NAME
-
Method Summary
Modifier and TypeMethodDescriptionname()
Gets the name of this algorithmstatic io.github.astrapi69.crypt.api.algorithm.Algorithm
newAlgorithm
(@NonNull String algorithm) Factory method for creating a newAlgorithm
from the given string algorithmMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface io.github.astrapi69.crypt.api.algorithm.Algorithm
getAlgorithm
-
Method Details
-
newAlgorithm
public static io.github.astrapi69.crypt.api.algorithm.Algorithm newAlgorithm(@NonNull @NonNull String algorithm) Factory method for creating a newAlgorithm
from the given string algorithm- Parameters:
algorithm
- the algorithm- Returns:
- the new
Algorithm
-
name
Gets the name of this algorithm- Returns:
- the name of this algorithm
-