Documents > BPS V2 C++ API
bpsschedule.h
Go to the documentation of this file.
00001 
00004 #ifndef BPSSCHEDULE_H
00005 #define BPSSCHEDULE_H
00006 
00007 #include "bpscore_global.h"
00008 #include <QDate>
00009 #include <QDateTime>
00010 #include <QMetaType>
00011 
00015 class BPSCORE_EXPORT BpsSchedule
00016 {
00017     BPS_PRIVATE(BpsSchedule)
00018 
00019 public:
00023     BpsSchedule();
00024 
00029     BpsSchedule(const BpsSchedule& aOther);
00030 
00034     BpsSchedule(const QString& aCronText);
00035 
00037     ~BpsSchedule();
00039 
00044     void setCronText(const QString& aCronText);
00045 
00049     QString cronText() const;
00050 
00055     bool minute(int aMinute) const;
00056 
00061     bool hour(int aHour) const;
00062 
00067     bool dayOfMonth(int aDayOfMonth) const;
00068 
00073     bool weekday(int aWeekday) const;
00074 
00079     bool weekday(const QString& aWeekday) const;
00080 
00085     bool month(int aMonth) const;
00086 
00091     bool month(const QString& aMonth) const;
00092 
00098     void setMinute(int aMinute, bool aEnable);
00099 
00105     void setHour(int aHour, bool aEnable);
00106 
00112     void setDayOfMonth(int aDayOfMonth, bool aEnable);
00113 
00119     void setWeekday(int aWeekday, bool aEnable);
00120 
00126     void setWeekday(const QString& aWeekday, bool aEnable);
00127 
00133     void setMonth(int aMonth, bool aEnable);
00134 
00140     void setMonth(const QString& aMonth, bool aEnable);
00141 
00147     bool isDateIncluded(const QDate& aDate) const;
00148 
00154     QDate nextDate(const QDate& aStart) const;
00155 
00161     QDate previousDate(const QDate& aStart) const;
00162 
00168     bool isDateTimeIncluded(const QDateTime& aDateTime) const;
00169 
00175     QDateTime nextDateTime(const QDateTime& aStart) const;
00176 
00182     QDateTime previousDateTime(const QDateTime& aStart) const;
00183 
00187     QTime firstTime() const;
00188 
00192     QTime lastTime() const;
00193 
00199     QDateTime firstDateTime(const QDate& aDate) const;
00200 
00206     QDateTime lastDateTime(const QDate& aDate) const;
00207 
00213     BpsSchedule& operator=(const BpsSchedule& aOther);
00214 
00215 };
00216 
00217 Q_DECLARE_METATYPE(BpsSchedule)
00218 
00219 #endif // BPSSCHEDULE_H