SevenZip Configuration
The class accepts one or more of the following configuration settings. Configuration settings are similar in functionality to properties, but they are rarely used. In order to avoid "polluting" the property namespace of the class, access to these internal properties is provided through the Config method.SevenZip Configuration Settings
BeginFileOnUpdate: Enables or disables events firing when updating existing archives.This setting controls whether or not events will fire when calling Update. The default value is False. If set to True, BeginFile and EndFile will fire before and after updating a file in an existing archive. | |
CheckForFileLocks:
If true, the component requests an exclusive lock during initialization.If set to true, the component will request an exclusive lock during initialization to ensure there are no other processes locking a file. This is a temporary lock and is released before work is done. This is especially useful when another process has a partial lock on a file, for instance when Outlook is working with a .pst.
False by default. | |
EnableFilter:
Enables or disables compression filters for executable files.When enabled, the class will apply compression filters as appropriate during compression. Filters are applied
to file executable file types: .dll, .exe, .ocx, .sfx, and .sys. Currently only the BCJ filter is used internally. The class
will automatically determine the files to which the filter is applied. The default value is True.
| |
EnableHeaderCompression: Enables or disables archive header compression.This setting controls whether or not header compression is used. When enabled some parts of the archive header will be compressed using the LZMA method. The default value is True. | |
EnableHeaderEncryption: Enables or disables archive header encryption.This setting controls whether or not header encryption is used. The default value is False. When set to True the filenames in the resulting archive will be encrypted. | |
ExcludedAttributes:
Attributes of files to be excluded.
Files with attributes matching those specified will be excluded from compression or decompression. May be set to any
combination of H (hidden), S (system), A (archive), and R (read-only).
(Example: "HSR") Alternatively, may be set to a bitmask of the following flags:
Readonly (1), Hidden (2), System (4), Directory (16), Archive (32).
For Java, when compressing, attributes other than "H" and "R" will be ignored (due to JRE limitations). Default: "" (no excluded attributes) | |
ExtractFilesOnly: Whether to only extract the files contained within the archive. If true, only the files contained within the ArchiveFile are extracted directly to the specified ExtractToPath. Folders contained within the ArchiveFile will not be created within the ExtractToPath. If an archive contains files with the same name, you can control whether or not they get overwritten by setting OverwriteFiles. | |
IsEncrypted: Indicates whether the archive is encrypted.This setting indicates whether the archive is encrypted. This may be queried after calling Scan. If the archive is encrypted Password must be set before calling Extract or ExtractAll. | |
OverwriteReadonlyFiles: Whether to overwrite readonly files. If true, the class will overwrite readonly files when decompressing. If false (the default), the class will fire the Error event, instead, and will fail with an exception if the error is not trapped and explicitly ignored in the event. | |
TempPath:
A temporary directory where data can be stored during processing.If set, this setting specifies a location on disk where data may be temporarily stored during processing. This can be
used to reduce memory consumption when processing large files. This will be used in situations where data must be held
internally during the operation, for instance when editing an existing archive.
The default value is empty string and data will not be written to disk. In most cases, using this setting will not be necessary. | |
WriteToProgressEvent:
Whether or not to write data to the Progress Event.If WriteToProgressEvent is set to true, then all data produced through invocations
of Extract, ExtractAll, and Compress will be written to the Progress
event as well as to disk. Applications may stream out the compressed or decompressed
data by trapping this event and copying the data.
If WriteToProgressEvent is set to false, the data will not be streamed out, and the Data parameter of the Progress event will contain null. Note that if streaming is enabled the zip files written will be slightly larger. Moreover, zip files produced with WriteToProgressEvent may be incompatible with certain older zip utilities. By default, Password encryption is not allowed for archives created with WriteToProgressEvent set to true. You may set the EnableStreamingEncryption setting to allow this, but streamed and encrypted zip files may be incompatible with other utilities. By default, this config is set to false. |
Base Configuration Settings
BuildInfo: Information about the product's build.When queried, this setting will return a string containing information about the product's build. | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
CodePage:
The system code page used for Unicode to Multibyte translations.The default code page is Unicode UTF-8 (65001).
The following is a list of valid code page identifiers:
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
LicenseInfo:
Information about the current license.When queried, this setting will return a string containing information about the license this instance of a class is using. It will return the following information:
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
UseInternalSecurityAPI: Tells the class whether or not to use the system security libraries or an internal implementation. By default the class will use the system security libraries to perform cryptographic functions. Setting this to True tells the class to use the internal implementation instead of using the system's security API. |