KDECore
ktzfiletimezone.h
Go to the documentation of this file.
00001 /* 00002 This file is part of the KDE libraries 00003 Copyright (c) 2005-2008 David Jarvie <djarvie@kde.org> 00004 00005 This library is free software; you can redistribute it and/or 00006 modify it under the terms of the GNU Library General Public 00007 License as published by the Free Software Foundation; either 00008 version 2 of the License, or (at your option) any later version. 00009 00010 This library is distributed in the hope that it will be useful, 00011 but WITHOUT ANY WARRANTY; without even the implied warranty of 00012 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 00013 Library General Public License for more details. 00014 00015 You should have received a copy of the GNU Library General Public License 00016 along with this library; see the file COPYING.LIB. If not, write to 00017 the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, 00018 Boston, MA 02110-1301, USA. 00019 */ 00020 00026 #ifndef _KTZFILETIMEZONE_H 00027 #define _KTZFILETIMEZONE_H 00028 00029 #include <kdecore_export.h> 00030 #include <ktimezone.h> 00031 00032 #include <QtCore/QString> 00033 00034 class KTzfileTimeZoneSource; 00035 class KTzfileTimeZonePrivate; 00036 class KTzfileTimeZoneDataPrivate; 00037 class KTzfileTimeZoneSourcePrivate; 00038 00050 class KDECORE_EXPORT KTzfileTimeZone : public KTimeZone //krazy:exclude=dpointer (no d-pointer for KTimeZone derived classes) 00051 { 00052 public: 00064 KTzfileTimeZone(KTzfileTimeZoneSource *source, const QString &name, 00065 const QString &countryCode = QString(), float latitude = UNKNOWN, float longitude = UNKNOWN, 00066 const QString &comment = QString()); 00067 00068 ~KTzfileTimeZone(); 00069 00070 private: 00071 // d-pointer is in KTzfileTimeZoneBackend. 00072 // This is a requirement for classes inherited from KTimeZone. 00073 }; 00074 00075 00089 class KDECORE_EXPORT KTzfileTimeZoneBackend : public KTimeZoneBackend //krazy:exclude=dpointer (non-const d-pointer for KTimeZoneBackend-derived classes) 00090 { 00091 public: 00093 KTzfileTimeZoneBackend(KTzfileTimeZoneSource *source, const QString &name, 00094 const QString &countryCode, float latitude, float longitude, const QString &comment); 00095 00096 ~KTzfileTimeZoneBackend(); 00097 00103 virtual KTimeZoneBackend *clone() const; 00104 00110 virtual QByteArray type() const; 00111 00120 virtual bool hasTransitions(const KTimeZone* caller) const; 00121 00122 private: 00123 KTzfileTimeZonePrivate *d; // non-const 00124 }; 00125 00126 00138 class KDECORE_EXPORT KTzfileTimeZoneSource : public KTimeZoneSource 00139 { 00140 public: 00151 explicit KTzfileTimeZoneSource(const QString &location); 00152 virtual ~KTzfileTimeZoneSource(); 00153 00159 QString location() const; 00160 00169 virtual KTimeZoneData *parse(const KTimeZone &zone) const; 00170 00171 private: 00172 KTzfileTimeZoneSourcePrivate * const d; 00173 }; 00174 00175 00185 class KTzfileTimeZoneData : public KTimeZoneData 00186 { 00187 friend class KTzfileTimeZoneSource; 00188 00189 public: 00190 KTzfileTimeZoneData(); 00191 KTzfileTimeZoneData(const KTzfileTimeZoneData &); 00192 virtual ~KTzfileTimeZoneData(); 00193 00194 KTzfileTimeZoneData &operator=(const KTzfileTimeZoneData &); 00195 00204 virtual KTimeZoneData *clone() const; 00205 00211 virtual bool hasTransitions() const; 00212 00213 private: 00214 // Enable this if you add KDECORE_EXPORT to this class 00215 //KTzfileTimeZoneDataPrivate * const d; 00216 }; 00217 00218 #endif
KDE 4.6 API Reference