|
| static void | saveBase (const std::filesystem::path &base_path, UDBase &col_base) |
| void | filesCollecting (const std::vector< std::filesystem::path > &files_and_dirs, UDBase &col_base) |
| size_t | countFiles (const std::vector< UDBElement > &el_v) |
| std::vector< std::tuple< const std::vector< UDBElement > *, std::vector< UDBElement >::const_iterator > > | getAllFiles (const std::vector< UDBElement > &el_v) |
| void | removeDublicates (std::vector< std::tuple< const std::vector< UDBElement > *, std::vector< UDBElement >::const_iterator > > &files) |
| void | processFiles (const std::vector< UDBElement > &items) |
| void | fileParsing (UDBElement *file) |
| void | cleanBase (std::vector< UDBElement > &items) |
| void | fb2Parsing (UDBElement *file, const std::filesystem::path &file_path) |
| void | epubParsing (UDBElement *file, const std::filesystem::path &file_path) |
| void | pdfParsing (UDBElement *file, const std::filesystem::path &file_path) |
| void | djvuParsing (UDBElement *file, const std::filesystem::path &file_path) |
| void | odtParsing (UDBElement *file, const std::filesystem::path &file_path) |
| void | txtParsing (UDBElement *file, const std::filesystem::path &file_path) |
| void | docParsing (UDBElement *file, const std::filesystem::path &file_path) |
| void | rtfParsing (UDBElement *file, const std::filesystem::path &file_path) |
| void | docxParsing (UDBElement *file, const std::filesystem::path &file_path) |
| void | mobiParsing (UDBElement *file, const std::filesystem::path &file_path) |
| void | archiveParsing (UDBElement *file, const std::filesystem::path &file_path) |
| std::string | bufferHash (const std::string &buf) |
| std::string | fileHash (const std::filesystem::path &file_path) |
| void | bufHash (UDBElement *file, const std::filesystem::path &file_path, const std::string &buf) |
| std::shared_ptr< MLBookProc > | mlbp |
| std::shared_ptr< std::vector< std::tuple< unsigned, bool > > > | threads_v |
| std::shared_ptr< std::mutex > | threads_v_mtx |
| std::shared_ptr< std::condition_variable > | threads_v_var |
| std::atomic< bool > | cancel |
| std::vector< std::shared_ptr< ArchiveParser > > | arch_proc |
| std::mutex | arch_proc_mtx |
| std::vector< std::tuple< std::filesystem::path, std::string > > | already_hashed |
| BaseID | bid |
| std::atomic< double > | processed |
| double | total |
The RefreshCollection class.
This class contains methods used for collection maintenance.
| void RefreshCollection::refreshCollection |
( |
const std::filesystem::path & | base_path, |
|
|
const bool & | fast_refresh = bool(true) ) |
Refreshes given collection.
Checks files existance and sizes. If size of file is not equal its database entry, file will be reparsed. If fast_refresh set to false, checks all files hash sums, and if file hash sum not equal its database entry, file will be reparsed. If given collection type is 'legacy' or 'inpx', collection will be recreated as 'native'.
- Parameters
-
| base_path | Path to collection database file. |
| fast_refresh | If true, file hash sums will not be checked. |