SevenZipEncryptionSettings

Inheritance: java.lang.Object

public abstract class SevenZipEncryptionSettings

Base class for settings for several 7z encryption methods.

The AES-256 is the only possible encryption method for 7z archive. So the SevenZipAESEncryptionSettings is the only implementation.

Methods

MethodDescription
getEncryptHeader()Gets a value indicating header encryption.
getPassword()Gets password for encryption or decryption.
setEncryptHeader(boolean value)Sets a value indicating header encryption.
setPassword(String value)Sets password for encryption or decryption.

getEncryptHeader()

public final boolean getEncryptHeader()

Gets a value indicating header encryption.

This setting is equivalent -mhe=on switch of 7-Zip tool. Currently it is incompatible with header compression.

Returns: boolean - a value indicating header encryption

getPassword()

public final String getPassword()

Gets password for encryption or decryption.

Returns: java.lang.String - password for encryption or decryption

setEncryptHeader(boolean value)

public final void setEncryptHeader(boolean value)

Sets a value indicating header encryption.

This setting is equivalent -mhe=on switch of 7-Zip tool. Currently it is incompatible with header compression.

Parameters:

ParameterTypeDescription
valuebooleana value indicating header encryption

setPassword(String value)

public final void setPassword(String value)

Sets password for encryption or decryption.

Parameters:

ParameterTypeDescription
valuejava.lang.Stringpassword for encryption or decryption