Package net.lingala.zip4j.model.enums
Enum AesVersion
- All Implemented Interfaces:
Serializable
,Comparable<AesVersion>
Indicates the AES format used
-
Enum Constant Summary
Enum Constants -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic AesVersion
getFromVersionNumber
(int versionNumber) Get the AESVersion instance from an integer AES version numberint
Get the AES version number as an integerstatic AesVersion
Returns the enum constant of this type with the specified name.static AesVersion[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
Enum Constant Details
-
ONE
Version 1 of the AES format -
TWO
Version 2 of the AES format
-
-
Field Details
-
versionNumber
private int versionNumber
-
-
Constructor Details
-
AesVersion
private AesVersion(int versionNumber)
-
-
Method Details
-
values
Returns an array containing the constants of this enum type, in the order they are declared.- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is null
-
getVersionNumber
public int getVersionNumber()Get the AES version number as an integer- Returns:
- the AES version number
-
getFromVersionNumber
Get the AESVersion instance from an integer AES version number- Returns:
- the AESVersion instance for a given version
- Throws:
IllegalArgumentException
- if an unsupported version is givenZipException
-