00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025 #ifndef KHOLIDAYS_HOLIDAY_H
00026 #define KHOLIDAYS_HOLIDAY_H
00027
00028 #include "kholidays_export.h"
00029
00030 #include <QtCore/QList>
00031 #include <QtCore/QSharedDataPointer>
00032
00033 class QDate;
00034 class QString;
00035
00036 namespace KHolidays {
00037
00038 class HolidayPrivate;
00039 class HolidayRegion;
00040
00041 class KHOLIDAYS_EXPORT Holiday
00042 {
00043 friend class HolidayRegion;
00044 friend class HolidayParserDriverPlan;
00045 friend class HolidayParserDriverPlanOld;
00046
00047 public:
00051 typedef QList<Holiday> List;
00052
00056 enum DayType {
00057 Workday,
00058 NonWorkday
00059 };
00060
00064 Holiday();
00065
00069 Holiday( const Holiday &other );
00070
00074 ~Holiday();
00075
00079 Holiday &operator=( const Holiday &other );
00080
00084 bool operator<( const Holiday &rhs ) const;
00085
00089 bool operator>( const Holiday &rhs ) const;
00090
00094 QDate date() const;
00095
00099 QString text() const;
00100
00104 QString shortText() const;
00105
00109 DayType dayType() const;
00110
00111 private:
00112 QSharedDataPointer<HolidayPrivate> d;
00113 };
00114
00115 }
00116
00117 #endif // KHOLIDAYS_HOLIDAY_H