1#ifndef SRC_SCANNER_LIB_SCANNER_BUILDER_H_
2#define SRC_SCANNER_LIB_SCANNER_BUILDER_H_
16 std::unique_ptr<IScanner>
Build()
override;
19 std::unique_ptr<IHashDatabase>
db_;
An interface for a builder that constructs a configured IScanner.
Definition interfaces.h:104
Definition scanner_builder.h:10
IScannerBuilder & WithMd5Hasher() override
Configures the scanner to use an MD5 file hasher.
Definition scanner_builder.cpp:30
std::unique_ptr< IScanner > Build() override
Builds the final IScanner instance.
Definition scanner_builder.cpp:40
std::unique_ptr< IFileHasher > hasher_
Definition scanner_builder.h:21
std::unique_ptr< IHashDatabase > db_
Definition scanner_builder.h:19
IScannerBuilder & WithThreads(std::size_t num_threads) override
Sets the number of threads for the scanner.
Definition scanner_builder.cpp:35
std::size_t num_threads_
Definition scanner_builder.h:22
IScannerBuilder & WithCsvDatabase(const std::filesystem::path &path) override
Configures the hash database from a CSV file.
Definition scanner_builder.cpp:16
IScannerBuilder & WithFileLogger(const std::filesystem::path &path) override
Configures the logger to write to a file.
Definition scanner_builder.cpp:24
std::unique_ptr< ILogger > logger_
Definition scanner_builder.h:20