10#ifndef BITITEMSVECTOR_HPP
11#define BITITEMSVECTOR_HPP
16#include "bitabstractarchivehandler.hpp"
18#include "bittypes.hpp"
30using filesystem::FilesystemItem;
32struct GenericInputItem;
37struct IndexingOptions {
38 bool recursive =
true;
39 bool retainFolderStructure =
false;
40 bool onlyFiles =
false;
41 bool followSymlinks =
true;
76 IndexingOptions options = {} );
130 BIT7Z_NODISCARD
auto size() const -> std::
size_t;
167 void indexItem( const FilesystemItem& item, IndexingOptions options );
The BitItemsVector class represents a vector of generic input items, i.e., items that can come from t...
Definition bititemsvector.hpp:49
auto cend() const noexcept -> GenericInputItemVector::const_iterator
auto end() const noexcept -> GenericInputItemVector::const_iterator
void indexBuffer(const std::vector< byte_t > &inBuffer, const tstring &name)
Indexes the given buffer, using the given name as a path when compressed in archives.
auto begin() const noexcept -> GenericInputItemVector::const_iterator
void indexFile(const tstring &inFile, const tstring &name={}, bool followSymlinks=true)
Indexes the given file path, with an optional user-defined path to be used in output archives.
void indexPathsMap(const std::map< tstring, tstring > &inPaths, IndexingOptions options={})
Indexes the given map of filesystem paths, adding to the vector all the files.
void indexStream(std::istream &inStream, const tstring &name)
Indexes the given standard input stream, using the given name as a path when compressed in archives.
void indexDirectory(const fs::path &inDir, const tstring &filter={}, FilterPolicy policy=FilterPolicy::Include, IndexingOptions options={})
Indexes the given directory, adding to the vector all the files that match the wildcard filter.
auto size() const -> std::size_t
void indexPaths(const std::vector< tstring > &inPaths, IndexingOptions options={})
Indexes the given vector of filesystem paths, adding to the item vector all the files.
auto cbegin() const noexcept -> GenericInputItemVector::const_iterator
The main namespace of the bit7z library.
Definition bit7zlibrary.hpp:30
FilterPolicy
Enumeration representing the policy according to which the archive handler should treat the items tha...
Definition bitabstractarchivehandler.hpp:66
@ Include
Extract/compress the items that match the pattern.