• Skip to content
  • Skip to link menu
  • KDE API Reference
  • kdelibs-4.10.5 API Reference
  • KDE Home
  • Contact Us
 

KDECore

Public Member Functions
KSystemTimeZone Class Reference
Time zone classes

#include <ksystemtimezone.h>

Inheritance diagram for KSystemTimeZone:
KTimeZone

List of all members.

Public Member Functions

 KSystemTimeZone (KSystemTimeZoneSource *source, const QString &name, const QString &countryCode=QString(), float latitude=UNKNOWN, float longitude=UNKNOWN, const QString &comment=QString())
 ~KSystemTimeZone ()
- Public Member Functions inherited from KTimeZone
 KTimeZone ()
 KTimeZone (const QString &name)
 KTimeZone (const KTimeZone &tz)
virtual ~KTimeZone ()
QByteArray abbreviation (const QDateTime &utcDateTime) const
QList< QByteArray > abbreviations () const
QString comment () const
QDateTime convert (const KTimeZone &newZone, const QDateTime &zoneDateTime) const
QString countryCode () const
int currentOffset (Qt::TimeSpec basis=Qt::UTC) const
const KTimeZoneData * data (bool create=false) const
virtual bool hasTransitions () const
virtual bool isDst (time_t t) const
virtual bool isDstAtUtc (const QDateTime &utcDateTime) const
bool isValid () const
float latitude () const
QList< LeapSeconds > leapSecondChanges () const
float longitude () const
QString name () const
virtual int offset (time_t t) const
virtual int offsetAtUtc (const QDateTime &utcDateTime) const
virtual int offsetAtZoneTime (const QDateTime &zoneDateTime, int *secondOffset=0) const
bool operator!= (const KTimeZone &rhs) const
KTimeZone & operator= (const KTimeZone &tz)
bool operator== (const KTimeZone &rhs) const
bool parse () const
QList< Phase > phases () const
KTimeZoneSource * source () const
QDateTime toUtc (const QDateTime &zoneDateTime) const
QDateTime toZoneTime (const QDateTime &utcDateTime, bool *secondOccurrence=0) const
const KTimeZone::Transition * transition (const QDateTime &dt, const Transition **secondTransition=0, bool *validTime=0) const
int transitionIndex (const QDateTime &dt, int *secondIndex=0, bool *validTime=0) const
QList< KTimeZone::Transition > transitions (const QDateTime &start=QDateTime(), const QDateTime &end=QDateTime()) const
QList< QDateTime > transitionTimes (const Phase &phase, const QDateTime &start=QDateTime(), const QDateTime &end=QDateTime()) const
QByteArray type () const
bool updateBase (const KTimeZone &other)
QList< int > utcOffsets () const

Additional Inherited Members

- Static Public Member Functions inherited from KTimeZone
static QDateTime fromTime_t (time_t t)
static time_t toTime_t (const QDateTime &utcDateTime)
static KTimeZone utc ()
- Static Public Attributes inherited from KTimeZone
static const int InvalidOffset = 0x80000000
static const time_t InvalidTime_t = 0x80000000
static const float UNKNOWN = 1000.0
- Protected Member Functions inherited from KTimeZone
 KTimeZone (KTimeZoneBackend *impl)
void setData (KTimeZoneData *data, KTimeZoneSource *source=0)

Detailed Description

The KSystemTimeZone class represents a time zone in the system database.

It works in partnership with the KSystemTimeZoneSource class which reads and parses the time zone definition files.

Typically, instances are created and accessed via the KSystemTimeZones class.

Warning:
The KSystemTimeZone class uses the standard system libraries to access time zone data, and its functionality is limited to what these libraries provide. On many systems, dates earlier than 1970 are not handled, and on non-GNU systems there is no guarantee that the time zone abbreviation returned for a given date will be correct if the abbreviations applicable then were not those currently in use. Consider using KSystemTimeZones::readZone() or the KTzfileTimeZone class instead, which provide accurate information from the time zone definition files (but are likely to incur more overhead).

System time zone

See also:
KSystemTimeZones, KSystemTimeZoneSource, KSystemTimeZoneData, KTzfileTimeZone
Author:
David Jarvie djarv.nosp@m.ie@k.nosp@m.de.or.nosp@m.g.

Definition at line 282 of file ksystemtimezone.h.


Constructor & Destructor Documentation

KSystemTimeZone::KSystemTimeZone ( KSystemTimeZoneSource *  source,
const QString &  name,
const QString &  countryCode = QString(),
float  latitude = UNKNOWN,
float  longitude = UNKNOWN,
const QString &  comment = QString() 
)

Creates a time zone.

Parameters:
sourcetzfile reader and parser
nametime zone's unique name
countryCodeISO 3166 2-character country code, empty if unknown
latitudein degrees (between -90 and +90), UNKNOWN if not known
longitudein degrees (between -180 and +180), UNKNOWN if not known
commentdescription of the time zone, if any

Definition at line 694 of file ksystemtimezone.cpp.

KSystemTimeZone::~KSystemTimeZone ( )

Definition at line 700 of file ksystemtimezone.cpp.


The documentation for this class was generated from the following files:
  • ksystemtimezone.h
  • ksystemtimezone.cpp
This file is part of the KDE documentation.
Documentation copyright © 1996-2013 The KDE developers.
Generated on Tue Jul 16 2013 17:47:39 by doxygen 1.8.1.1 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

KDECore

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

kdelibs-4.10.5 API Reference

Skip menu "kdelibs-4.10.5 API Reference"
  • DNSSD
  • Interfaces
  •   KHexEdit
  •   KMediaPlayer
  •   KSpeech
  •   KTextEditor
  • kconf_update
  • KDE3Support
  •   KUnitTest
  • KDECore
  • KDED
  • KDEsu
  • KDEUI
  • KDEWebKit
  • KDocTools
  • KFile
  • KHTML
  • KImgIO
  • KInit
  • kio
  • KIOSlave
  • KJS
  •   KJS-API
  •   WTF
  • kjsembed
  • KNewStuff
  • KParts
  • KPty
  • Kross
  • KUnitConversion
  • KUtils
  • Nepomuk
  • Plasma
  • Solid
  • Sonnet
  • ThreadWeaver
Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal