diff --git a/common/include/System.h b/common/include/System.h index 918aff6..4c59a04 100644 --- a/common/include/System.h +++ b/common/include/System.h @@ -3,6 +3,10 @@ #include +#include + +#include +#include class System : public QObject { @@ -13,16 +17,17 @@ private: static QString errorMsg; - public: + static const QStringList allowedJsonFiles; static bool checkForSDCard(); static bool umountSDCard(); - static bool checkForUSBStick(); - static QString getUSBMountPath(); - static QString getUSBDeviceName(); + static std::optional checkForUSBStick(QString const &dirPathUnderMountPath = "."); + static QString getUSBMountPath(QString const &dirPathUnderMountPath = "."); + + //static QString getUSBDeviceName(); static bool umountUSBStick(); static bool test_mount(const QString& dev, const QString &mountpoint); @@ -48,7 +53,7 @@ public: static QString getPTU4SerialNumber(); static QString getPTU4MACAddress(); - + static QStringList getJsonFilesOnUsbStick(QString const &mountPath); };