• Skip to content
  • Skip to link menu
  • KDE API Reference
  • kdepimlibs-4.14.10 API Reference
  • KDE Home
  • Contact Us
 

KCal Library

  • KCal
  • ICalTimeZone
Public Member Functions | Static Public Member Functions | List of all members
KCal::ICalTimeZone Class Reference

#include <icaltimezones.h>

Inherits KTimeZone.

Public Member Functions

 ICalTimeZone ()
 
 ICalTimeZone (const KTimeZone &tz, const QDate &earliest=QDate())
 
 ICalTimeZone (ICalTimeZoneSource *source, const QString &name, ICalTimeZoneData *data)
 
virtual ~ICalTimeZone ()
 
QString city () const
 
icaltimezone * icalTimezone () const
 
QDateTime lastModified () const
 
bool update (const ICalTimeZone &other)
 
QByteArray url () const
 
QByteArray vtimezone () const
 

Static Public Member Functions

static ICalTimeZone utc ()
 

Detailed Description

The ICalTimeZone class represents an iCalendar VTIMEZONE component.

ICalTimeZone instances are normally created by ICalTimeZoneSource::parse().

An iCalendar time zone

See also
ICalTimeZoneSource, ICalTimeZoneData
Author
David Jarvie softw.nosp@m.are@.nosp@m.astro.nosp@m.jar..nosp@m.org.u.nosp@m.k.

Definition at line 142 of file icaltimezones.h.

Constructor & Destructor Documentation

◆ ICalTimeZone() [1/3]

KCal::ICalTimeZone::ICalTimeZone ( )

Constructs a null time zone.

A null time zone is invalid.

See also
isValid()

Definition at line 207 of file icaltimezones.cpp.

◆ ICalTimeZone() [2/3]

KCal::ICalTimeZone::ICalTimeZone ( ICalTimeZoneSource * source,
const QString & name,
ICalTimeZoneData * data )

Creates a time zone.

This constructor is normally called from ICalTimeZoneSource::parse().

Parameters
sourceiCalendar VTIMEZONE reader and parser
nametime zone's unique name within the iCalendar object
dataparsed VTIMEZONE data

Definition at line 211 of file icaltimezones.cpp.

◆ ICalTimeZone() [3/3]

KCal::ICalTimeZone::ICalTimeZone ( const KTimeZone & tz,
const QDate & earliest = QDate() )
explicit

Constructor which converts a KTimeZone to an ICalTimeZone instance.

Parameters
tzKTimeZone instance
earliestearliest date for which time zone data should be stored

Definition at line 218 of file icaltimezones.cpp.

◆ ~ICalTimeZone()

KCal::ICalTimeZone::~ICalTimeZone ( )
virtual

Destructor.

Definition at line 234 of file icaltimezones.cpp.

Member Function Documentation

◆ city()

QString KCal::ICalTimeZone::city ( ) const

Returns the name of the city for this time zone, if any.

There is no fixed format for the name.

Returns
city name

Definition at line 237 of file icaltimezones.cpp.

◆ icalTimezone()

icaltimezone * KCal::ICalTimeZone::icalTimezone ( ) const

Returns the ICal timezone structure which represents this time zone.

The caller is responsible for freeing the returned structure using icaltimezone_free().

Returns
icaltimezone structure

Definition at line 261 of file icaltimezones.cpp.

◆ lastModified()

QDateTime KCal::ICalTimeZone::lastModified ( ) const

Returns the LAST-MODIFIED time of the VTIMEZONE, if any.

Returns
time, or QDateTime() if none

Definition at line 249 of file icaltimezones.cpp.

◆ update()

bool KCal::ICalTimeZone::update ( const ICalTimeZone & other)

Update the definition of the time zone to be identical to another ICalTimeZone instance.

A prerequisite is that the two instances must have the same name.

The purpose of this method is to enable updates of ICalTimeZone definitions when a calendar is reloaded, without invalidating pointers to the instance (particularly pointers held by KDateTime objects).

Parameters
othertime zone whose definition is to be used
Returns
true if definition was updated (i.e. names are the same)

Definition at line 267 of file icaltimezones.cpp.

◆ url()

QByteArray KCal::ICalTimeZone::url ( ) const

Returns the URL of the published VTIMEZONE definition, if any.

Returns
URL

Definition at line 243 of file icaltimezones.cpp.

◆ utc()

ICalTimeZone KCal::ICalTimeZone::utc ( )
static

Returns a standard UTC time zone, with name "UTC".

Note
The ICalTimeZone returned by this method does not belong to any ICalTimeZones collection. Any ICalTimeZones instance may contain its own UTC ICalTimeZone defined by its time zone source data, but that will be a different instance than this ICalTimeZone.
Returns
UTC time zone

Definition at line 278 of file icaltimezones.cpp.

◆ vtimezone()

QByteArray KCal::ICalTimeZone::vtimezone ( ) const

Returns the VTIMEZONE string which represents this time zone.

Returns
VTIMEZONE string

Definition at line 255 of file icaltimezones.cpp.


The documentation for this class was generated from the following files:
  • icaltimezones.h
  • icaltimezones.cpp
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Wed Jan 24 2024 00:00:00 by doxygen 1.10.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

KCal Library

Skip menu "KCal Library"
  • Main Page
  • Namespace List
  • Namespace Members
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • File Members
  • Related Pages

kdepimlibs-4.14.10 API Reference

Skip menu "kdepimlibs-4.14.10 API Reference"
  • akonadi
  •   contact
  •   kmime
  •   socialutils
  • kabc
  • kalarmcal
  • kblog
  • kcal
  • kcalcore
  • kcalutils
  • kholidays
  • kimap
  • kioslave
  •   imap4
  •   mbox
  •   nntp
  • kldap
  • kmbox
  • kmime
  • kontactinterface
  • kpimidentities
  • kpimtextedit
  • kpimutils
  • kresources
  • ktnef
  • kxmlrpcclient
  • mailtransport
  • microblog
  • qgpgme
  • syndication
  •   atom
  •   rdf
  •   rss2
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