Add a printer factory to simplify construction of printer drivers (#11)
All checks were successful
Build ptprnt / build (push) Successful in 1m1s

Co-authored-by: Moritz Martinius <mm@cloudprinters.de>
Reviewed-on: #11
This commit is contained in:
2024-04-20 11:10:30 +00:00
parent 5b3148cb65
commit ad0b2c91ae
17 changed files with 231 additions and 87 deletions

View File

@@ -49,13 +49,12 @@ class PtouchPrint {
// methods
void setupLogger(spdlog::level::level_enum lvl);
void setupCliParser();
unsigned int getCompatiblePrinters();
std::vector<std::shared_ptr<IPrinterDriver>> getCompatiblePrinters();
// member variables
CLI::App mApp{ptprnt::APP_DESC};
libusbwrap::UsbDeviceFactory mUsbDeviceFactory{};
std::vector<std::shared_ptr<ptprnt::IPrinterDriver>> mCompatiblePrinters{};
std::vector<std::shared_ptr<ptprnt::IPrinterDriver>> mDetectedPrinters{};
std::vector<std::shared_ptr<IPrinterDriver>> mDetectedPrinters{};
std::vector<CliCmd> mCommands{};
std::string mVersionString = "";