| 1 | /* ------------------ scheduleClass.h -------------------------------------------------------------------------------------- |
| 2 | header file for luckyBackup project |
| 3 | |
| 4 | =============================================================================================================================== |
| 5 | =============================================================================================================================== |
| 6 | This file is part of "luckyBackup" project |
| 7 | Copyright, Loukas Avgeriou |
| 8 | luckyBackup is distributed under the terms of the GNU General Public License |
| 9 | luckyBackup is free software: you can redistribute it and/or modify |
| 10 | it under the terms of the GNU General Public License as published by |
| 11 | the Free Software Foundation, either version 3 of the License, or |
| 12 | (at your option) any later version. |
| 13 | |
| 14 | luckyBackup is distributed in the hope that it will be useful, |
| 15 | but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 16 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 17 | GNU General Public License for more details. |
| 18 | |
| 19 | You should have received a copy of the GNU General Public License |
| 20 | along with luckyBackup. If not, see <http://www.gnu.org/licenses/>. |
| 21 | |
| 22 | |
| 23 | project version : Please see "main.cpp" for project version |
| 24 | |
| 25 | developer : luckyb |
| 26 | last modified : 24 Jan 2011 |
| 27 | =============================================================================================================================== |
| 28 | =============================================================================================================================== |
| 29 | */ |
| 30 | |
| 31 | |
| 32 | |
| 33 | #ifndef SCHEDULECLASS_H |
| 34 | #define SCHEDULECLASS_H |
| 35 | |
| 36 | |
| 37 | //============================================================================================================== |
| 38 | //Declaration of schedule class (this is the class that holds profiles scheduling names & arguments) |
| 39 | class schedule |
| 40 | { |
| 41 | public: |
| 42 | schedule() //constructor |
| 43 | { |
| 44 | itsName= ""; |
| 45 | itsProfilePath = ""; |
| 46 | itsProfileName = ""; |
| 47 | itsMonth = 0; |
| 48 | itsMonthDay = 0; |
| 49 | itsWeekDay = 0; |
| 50 | itsHour = 0; |
| 51 | itsMinute = 0; |
| 52 | itsSkipCritical = true; |
| 53 | itsConsoleMode = false; |
| 54 | itsReboot = false; |
| 55 | itsDelayReboot = 3; |
| 56 | } |
| 57 | ~schedule() {} //destructor |
| 58 | |
| 59 | //Functions - get class operation data-------------------------------------------------------------------------------------- |
| 60 | QString GetName() const {return itsName;} |
| 61 | QString GetProfilePath() const {return itsProfilePath;} |
| 62 | QString GetProfileName() const {return itsProfileName;} |
| 63 | |
| 64 | int GetMonth () const {return itsMonth;} |
| 65 | int GetMonthDay () const {return itsMonthDay;} |
| 66 | int GetWeekDay () const {return itsWeekDay;} |
| 67 | int GetHour () const {return itsHour;} |
| 68 | int GetMinute () const {return itsMinute;} |
| 69 | bool GetSkipCritical() const {return itsSkipCritical;} |
| 70 | bool GetConsoleMode() const {return itsConsoleMode;} |
| 71 | bool GetReboot() const {return itsReboot;} |
| 72 | int GetDelayReboot () const {return itsDelayReboot;} |
| 73 | |
| 74 | //Functions - set class operation data -------------------------------------------------------------------------------------- |
| 75 | void SetName(QString name) {itsName = name;} |
| 76 | |
| 77 | void SetProfilePath(QString ProfilePath) {itsProfilePath = ProfilePath;} |
| 78 | void SetProfileName(QString ProfileName) {itsProfileName = ProfileName;} |
| 79 | |
| 80 | void SetMonth(int month) {itsMonth = month;} |
| 81 | void SetMonthDay(int monthDay) {itsMonthDay = monthDay;} |
| 82 | void SetWeekDay(int weekDay) {itsWeekDay = weekDay;} |
| 83 | void SetHour(int hour) {itsHour = hour;} |
| 84 | void SetMinute(int minute) {itsMinute = minute;} |
| 85 | void SetSkipCritical (bool SkipCritical) {itsSkipCritical = SkipCritical;} |
| 86 | void SetConsoleMode (bool ConsoleMode) {itsConsoleMode = ConsoleMode;} |
| 87 | void SetReboot (bool Reboot) {itsReboot = Reboot;} |
| 88 | void SetDelayReboot (int delayReboot) {itsDelayReboot = delayReboot;} |
| 89 | |
| 90 | private: |
| 91 | QString itsName; |
| 92 | QString itsProfilePath; |
| 93 | QString itsProfileName; |
| 94 | int itsMonth; |
| 95 | int itsMonthDay; |
| 96 | int itsWeekDay; |
| 97 | int itsHour; |
| 98 | int itsMinute; |
| 99 | bool itsSkipCritical; |
| 100 | bool itsConsoleMode; |
| 101 | bool itsReboot; |
| 102 | int itsDelayReboot; |
| 103 | }; |
| 104 | |
| 105 | #endif |
| 106 | |
| 107 | // end of scheduleClass.h-------------------------------------------------------------- |