• Skip to content
  • Skip to link menu
Trinity API Reference
  • Trinity API Reference
  • kdecore
 

kdecore

  • kdecore
kcalendarsystem.h
1 /*
2  Copyright (c) 2002 Carlos Moro <cfmoro@correo.uniovi.es>
3  Copyright (c) 2002-2003 Hans Petter Bieker <bieker@kde.org>
4 
5  This library is free software; you can redistribute it and/or
6  modify it under the terms of the GNU Library General Public
7  License as published by the Free Software Foundation; either
8  version 2 of the License, or (at your option) any later version.
9 
10  This library is distributed in the hope that it will be useful,
11  but WITHOUT ANY WARRANTY; without even the implied warranty of
12  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13  Library General Public License for more details.
14 
15  You should have received a copy of the GNU Library General Public License
16  along with this library; see the file COPYING.LIB. If not, write to
17  the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
18  Boston, MA 02110-1301, USA.
19 */
20 
21 #ifndef KCALENDARSYSTEM_H
22 #define KCALENDARSYSTEM_H
23 
24 #include <tqdatetime.h>
25 #include <tqstring.h>
26 #include "kdelibs_export.h"
27 
28 class KLocale;
29 
30 class KCalendarSystemPrivate;
31 
42 class KDECORE_EXPORT KCalendarSystem
43 {
44 public:
50  KCalendarSystem(const KLocale * locale = 0);
51 
55  virtual ~KCalendarSystem();
56 
63  virtual int year (const TQDate & date) const = 0;
64 
72  virtual TQString yearString(const TQDate & pDate, bool bShort) const;
73 
81  virtual int yearStringToInteger(const TQString & sNum, int & iLength) const;
82 
89  virtual int month (const TQDate & date) const = 0;
90 
98  virtual TQString monthString(const TQDate & pDate, bool bShort) const;
99 
107  virtual int monthStringToInteger(const TQString & sNum, int & iLength) const;
108 
115  virtual int day (const TQDate & date) const = 0;
116 
124  virtual TQString dayString(const TQDate & pDate, bool bShort) const;
125 
133  virtual int dayStringToInteger(const TQString & sNum, int & iLength) const;
134 
142  virtual int dayOfWeek (const TQDate & date) const = 0;
143 
150  virtual int dayOfYear (const TQDate & date) const = 0;
151 
162  virtual bool setYMD(TQDate & date, int y, int m, int d) const = 0;
163 
171  virtual TQDate addYears(const TQDate & date, int nyears) const = 0;
172 
180  virtual TQDate addMonths(const TQDate & date, int nmonths) const = 0;
181 
189  virtual TQDate addDays(const TQDate & date, int ndays) const = 0;
190 
197  virtual int monthsInYear (const TQDate & date) const = 0;
198 
205  virtual int daysInYear (const TQDate & date) const = 0;
206 
213  virtual int daysInMonth (const TQDate & date) const = 0;
214 
221  virtual int weeksInYear(int year) const = 0;
222 
230  virtual int weekNumber(const TQDate& date, int * yearNum = 0) const = 0;
231 
241  virtual TQString monthName (int month, int year, bool shortName = false) const = 0;
242 
250  virtual TQString monthName (const TQDate & date, bool shortName = false ) const = 0;
251 
264  virtual TQString monthNamePossessive(int month, int year, bool shortName = false) const = 0;
265 
276  virtual TQString monthNamePossessive(const TQDate & date, bool shortName = false) const = 0;
277 
286  virtual TQString weekDayName (int weekDay, bool shortName = false) const = 0;
287 
295  virtual TQString weekDayName (const TQDate & date, bool shortName = false) const = 0;
296 
303  virtual int minValidYear () const = 0;
304 
311  virtual int maxValidYear () const = 0;
312 
318  virtual int weekDayOfPray () const = 0;
319 
323  virtual TQString calendarName() const = 0;
324 
330  virtual bool isLunar() const = 0;
331 
337  virtual bool isLunisolar() const = 0;
338 
344  virtual bool isSolar() const = 0;
345 
346 protected:
351  const KLocale * locale() const;
352 
353 private:
354  KCalendarSystemPrivate * d;
355 };
356 
357 #endif

kdecore

Skip menu "kdecore"
  • Main Page
  • Modules
  • Namespace List
  • Class Hierarchy
  • Alphabetical List
  • Class List
  • File List
  • Namespace Members
  • Class Members
  • Related Pages

kdecore

Skip menu "kdecore"
  • arts
  • dcop
  • dnssd
  • interfaces
  •     interface
  •     library
  •   kspeech
  •   ktexteditor
  • kabc
  • kate
  • kcmshell
  • kdecore
  • kded
  • kdefx
  • kdeprint
  • kdesu
  • kdeui
  • kdoctools
  • khtml
  • kimgio
  • kinit
  • kio
  •   bookmarks
  •   httpfilter
  •   kfile
  •   kio
  •   kioexec
  •   kpasswdserver
  •   kssl
  • kioslave
  •   http
  • kjs
  • kmdi
  •   kmdi
  • knewstuff
  • kparts
  • krandr
  • kresources
  • kspell2
  • kunittest
  • kutils
  • kwallet
  • libkmid
  • libkscreensaver
Generated for kdecore by doxygen 1.8.1.2
This website is maintained by Timothy Pearson.
KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. |