BigBlueBox
An Inventory Management System for a NYLT Course or other Boy Scout Programs
 All Classes Namespaces Files Functions Variables Enumerations Enumerator Pages
_settings.h
Go to the documentation of this file.
1 #ifndef _SETTINGS_H
2 #define _SETTINGS_H
3 
4 #include <QJsonDocument>
5 #include <QJsonObject>
6 #include <QJsonArray>
7 #include <QJsonValuePtr>
8 
9 #include <QCoreApplication>
10 
11 #include <directoryhandler.h>
12 
13 namespace bbb {
14 class _Settings
15 {
16 private:
17  QString jsonPath;
18  QString tempAppName;
19 
20  QJsonDocument readFile(QString path);
21 
22 
23 public:
24  _Settings();
25  ~_Settings();
26 
27  void appNamePassThough(QString name);
28 
29  //**********************************************
30  // Application Settings
31  //**********************************************
32  void restoreDefaults();
33 
34  QString getAppColorTheme();
35  static void setAppColorTheme(QString theme);
36 
37  //**********************************************
38 
39 
40  //**********************************************
41  // Database Settings
42  //**********************************************
43  static QString getDbType();
44  static void setDbType(QString type);
45 
46  static QString getDbLoc();
47  static void setDbLoc(QString location);
48 
49  static QString getDbPath();
50  static void setDbPath(QString path);
51 
52  static QString getDbIPAddress();
53  static void setDbIPAddress(QString addr);
54 
55  static QString getDbPort();
56  static void setDbPort(QString port);
57 
58  static QString getDbUserName();
59  static void setDbUserName(QString username);
60 
61  static QString getDbPW();
62  static void setDbPW(QString pw);
63  //**********************************************
64 
65 
66 };
67 }
68 
69 #endif // _SETTINGS_H
QString jsonPath
Definition: _settings.h:17
QString getAppColorTheme()
Definition: _settings.cpp:56
QJsonDocument readFile(QString path)
Definition: _settings.cpp:36
static void setDbPath(QString path)
static QString getDbPath()
static void setDbUserName(QString username)
static QString getDbUserName()
static void setAppColorTheme(QString theme)
Definition: _settings.cpp:82
static QString getDbIPAddress()
static void setDbPW(QString pw)
static QString getDbPort()
static QString getDbType()
static QString getDbPW()
static void setDbType(QString type)
static QString getDbLoc()
static void setDbLoc(QString location)
QString tempAppName
Definition: _settings.h:18
static void setDbIPAddress(QString addr)
_Settings()
Definition: _settings.cpp:6
Definition: _settings.h:14
void appNamePassThough(QString name)
Definition: _settings.cpp:29
~_Settings()
Definition: _settings.cpp:23
static void setDbPort(QString port)
void restoreDefaults()