10#ifndef BITARCHIVEREADER_HPP
11#define BITARCHIVEREADER_HPP
13#include "bitabstractarchiveopener.hpp"
14#include "bitarchiveiteminfo.hpp"
15#include "bitexception.hpp"
16#include "bitinputarchive.hpp"
20struct IArchiveExtractCallback;
121 BIT7Z_NODISCARD auto
size() const -> uint64_t;
164 template< typename T >
173 return isOpenEncryptedError( ex.code() );
193 template<
typename T >
200 return reader.isEncrypted();
202 return isOpenEncryptedError( ex.code() );
210using BitArchiveInfo BIT7Z_MAYBE_UNUSED BIT7Z_DEPRECATED_MSG(
"Since v4.0; please use BitArchiveReader.") = BitArchiveReader;
The Bit7zLibrary class allows accessing the basic functionalities provided by the 7z DLLs.
Definition bit7zlibrary.hpp:56
auto password() const -> tstring
The BitAbstractArchiveOpener abstract class represents a generic archive opener.
Definition bitabstractarchiveopener.hpp:26
auto format() const noexcept -> const BitInFormat &override
The BitArchiveItemInfo class represents an archived item and that stores all its properties for later...
Definition bitarchiveiteminfo.hpp:25
The BitArchiveReader class allows reading metadata of archives, as well as extracting them.
Definition bitarchivereader.hpp:27
auto items() const -> vector< BitArchiveItemInfo >
static auto isHeaderEncrypted(const Bit7zLibrary &lib, T &&inArchive, const BitInFormat &format=BitFormat::Auto) -> bool
Checks if the given archive is header-encrypted or not.
Definition bitarchivereader.hpp:166
auto isMultiVolume() const -> bool
auto foldersCount() const -> uint32_t
auto isEncrypted() const -> bool
auto volumesCount() const -> uint32_t
~BitArchiveReader() override=default
BitArchiveReader destructor.
auto size() const -> uint64_t
BitArchiveReader(const Bit7zLibrary &lib, const tstring &inArchive, const BitInFormat &format=BitFormat::Auto, const tstring &password={})
Constructs a BitArchiveReader object, opening the input file archive.
auto hasEncryptedItems() const -> bool
auto packSize() const -> uint64_t
auto isSolid() const -> bool
BitArchiveReader(const Bit7zLibrary &lib, const std::vector< byte_t > &inArchive, const BitInFormat &format=BitFormat::Auto, const tstring &password={})
Constructs a BitArchiveReader object, opening the archive in the input buffer.
static auto isEncrypted(const Bit7zLibrary &lib, T &&inArchive, const BitInFormat &format=BitFormat::Auto) -> bool
Checks if the given archive contains only encrypted items.
Definition bitarchivereader.hpp:195
BitArchiveReader(const Bit7zLibrary &lib, std::istream &inArchive, const BitInFormat &format=BitFormat::Auto, const tstring &password={})
Constructs a BitArchiveReader object, opening the archive from the standard input stream.
auto filesCount() const -> uint32_t
auto archiveProperties() const -> map< BitProperty, BitPropVariant >
The BitException class represents a generic exception thrown from the bit7z classes.
Definition bitexception.hpp:32
The main namespace of the bit7z library.
Definition bit7zlibrary.hpp:30
BitProperty
The BitProperty enum represents the archive/item properties that 7-zip can read or write.
Definition bitpropvariant.hpp:30
The BitPropVariant struct is a light extension to the WinAPI PROPVARIANT struct providing useful gett...
Definition bitpropvariant.hpp:150