struct RAROpenArchiveDataEx
{
char *ArcName;
wchar_t *ArcNameW;
unsigned int OpenMode;
unsigned int OpenResult;
char *CmtBuf;
unsigned int CmtBufSize;
unsigned int CmtSize;
unsigned int CmtState;
unsigned int Flags;
UNRARCALLBACK Callback;
LPARAM UserData;
unsigned int OpFlags;
wchar_t *CmtBufW;
unsigned int Reserved[25];
};
This structure is used by RAROpenArchiveEx function.
Input parameter which should point to zero terminated string containing the archive name or NULL if only Unicode name is specified.
Input parameter which should point to zero terminated Unicode string containing the archive name or NULL if Unicode name is not specified.
Input parameter.
Possible values
- RAR_OM_LIST
Open archive for reading file headers only.
- RAR_OM_EXTRACT
Open archive for testing and extracting files.
- RAR_OM_LIST_INCSPLIT
Open archive for reading file headers only. If you open an archive in such mode, RARReadHeader[Ex] will return all file headers, including those with "file continued from previous volume" flag. In case of RAR_OM_LIST such headers are automatically skipped. So if you process RAR volumes in RAR_OM_LIST_INCSPLIT mode, you will get several file header records for same file if file is split between volumes. For such files only the last file header record will contain the correct file CRC and if you wish to get the correct packed size, you need to sum up packed sizes of all parts.
Output parameter.
Possible values:
0 Success ERAR_NO_MEMORY Not enough memory to initialize data structures ERAR_BAD_DATA Archive header broken ERAR_UNKNOWN_FORMAT Unknown encryption used for archive headers ERAR_EOPEN File open error ERAR_BAD_PASSWORD Entered password is invalid. This code is returned only for archives in RAR 5.0 format
Input parameter which should point to buffer for archive comment. Comment text is zero terminated. If comment text is larger than buffer size, comment text is truncated.
Comment is read in a native single byte encoding. If you need Unicode comment, use CmtBufW.
Set to NULL if you do not need to read non-Unicode comment.
Input parameter which should contain a size of buffer for archive comments. Used either with CmtBuf or CmtBufW. Size is specified in characters, which are a single byte for CmtBuf or wchar_t size for CmtBufW.
Output parameter containing a size of comment actually read into the buffer, cannot exceed CmtBufSize. Used either with CmtBuf or CmtBufW. Size is returned in characters, which are a single byte for CmtBuf or wchar_t size for CmtBufW.
Output parameter.
Possible values:
0 Comments are not present 1 Comments are read completely ERAR_NO_MEMORY Not enough memory to extract comments ERAR_BAD_DATA Broken comment ERAR_SMALL_BUF Buffer is too small, comments are not read completely.
Output parameter. Combination of bit flags.
Possible values:
ROADF_VOLUME 0x0001 Volume attribute (archive volume) ROADF_COMMENT 0x0002 Archive comment present ROADF_LOCK 0x0004 Archive lock attribute ROADF_SOLID 0x0008 Solid attribute (solid archive) ROADF_NEWNUMBERING 0x0010 New volume naming scheme ('volname.partN.rar') ROADF_SIGNED 0x0020 Authenticity information present (obsolete) ROADF_RECOVERY 0x0040 Recovery record present ROADF_ENCHEADERS 0x0080 Block headers are encrypted ROADF_FIRSTVOLUME 0x0100 First volume (set only by RAR 3.0 and later)
Address of user defined callback function to process UnRAR events.
Set it to NULL if you do not want to define the callback function. Callback function is required to process multivolume and encrypted archives properly.
User defined value, which will be passed to callback function.
Input parameter. Operation mode modifiers. Combination of bit flags.
Possible values:
ROADOF_KEEPBROKEN 0x0001 If set, extracted files with checksum errors are not deleted
Input parameter which should point to buffer for archive comment in Unicode encoding. Comment text is zero terminated. If comment text is larger than buffer size, comment text is truncated.
Set to NULL if you do not need to read Unicode comment.
If both CmtBuf and CmtBufW are not NULL, only CmtBufW comment is read. If both CmtBuf and CmtBufW are NULL, archive comment is not read.
Reserved for future use. Must be zero.
RAROpenArchiveEx function.
User defined callback function