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

KCal Library

  • kcal
freebusyperiod.cpp
Go to the documentation of this file.
1/*
2 This file is part of the kcal library.
3
4 Copyright (c) 2001 Cornelius Schumacher <schumacher@kde.org>
5 Copyright (c) 2007 David Jarvie <software@astrojar.org.uk>
6
7 This library is free software; you can redistribute it and/or
8 modify it under the terms of the GNU Library General Public
9 License as published by the Free Software Foundation; either
10 version 2 of the License, or (at your option) any later version.
11
12 This library is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 Library General Public License for more details.
16
17 You should have received a copy of the GNU Library General Public License
18 along with this library; see the file COPYING.LIB. If not, write to
19 the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
20 Boston, MA 02110-1301, USA.
21*/
33#include "freebusyperiod.h"
34
35#include <kdebug.h>
36#include <klocalizedstring.h>
37
38using namespace KCal;
39
40//@cond PRIVATE
41class KCal::FreeBusyPeriod::Private
42{
43 public:
44 Private() {}
45
46 QString mSummary;
47 QString mLocation;
48};
49//@endcond
50
51FreeBusyPeriod::FreeBusyPeriod() : Period(), d( new KCal::FreeBusyPeriod::Private() )
52{
53}
54
55FreeBusyPeriod::FreeBusyPeriod( const KDateTime &start, const KDateTime &end )
56 : Period( start, end ), d( new KCal::FreeBusyPeriod::Private() )
57{
58}
59
60FreeBusyPeriod::FreeBusyPeriod( const KDateTime &start, const Duration &duration )
61 : Period( start, duration ), d( new KCal::FreeBusyPeriod::Private() )
62{
63}
64
65FreeBusyPeriod::FreeBusyPeriod( const FreeBusyPeriod &period )
66 : Period( period ), d( new KCal::FreeBusyPeriod::Private( *period.d ) )
67{
68}
69
70FreeBusyPeriod::FreeBusyPeriod( const Period &period )
71 : Period( period ), d( new KCal::FreeBusyPeriod::Private() )
72{
73}
74
75FreeBusyPeriod::~FreeBusyPeriod()
76{
77 delete d;
78}
79
80FreeBusyPeriod &FreeBusyPeriod::operator=( const FreeBusyPeriod &other )
81{
82 // check for self assignment
83 if ( &other == this ) {
84 return *this;
85 }
86
87 Period::operator=(other);
88 *d = *other.d;
89 return *this;
90}
91
92QString FreeBusyPeriod::summary() const
93{
94 return d->mSummary;
95}
96
97void FreeBusyPeriod::setSummary( const QString &summary )
98{
99 d->mSummary = summary;
100}
101
102QString FreeBusyPeriod::location() const
103{
104 return d->mLocation;
105}
106
107void FreeBusyPeriod::setLocation( const QString &location )
108{
109 d->mLocation = location;
110}
KCal::Duration
Represents a span of time measured in seconds or days.
Definition: duration.h:53
KCal::FreeBusyPeriod
The period can be defined by either a start time and an end time or by a start time and a duration.
Definition: freebusyperiod.h:49
KCal::FreeBusyPeriod::FreeBusyPeriod
FreeBusyPeriod()
Constructs a period without a duration.
Definition: freebusyperiod.cpp:51
KCal::FreeBusyPeriod::operator=
FreeBusyPeriod & operator=(const FreeBusyPeriod &other)
Sets this period equal to the other one.
Definition: freebusyperiod.cpp:80
KCal::FreeBusyPeriod::~FreeBusyPeriod
~FreeBusyPeriod()
Destroys a period.
Definition: freebusyperiod.cpp:75
KCal::Period
The period can be defined by either a start time and an end time or by a start time and a duration.
Definition: period.h:48
KCal::Period::operator=
Period & operator=(const Period &other)
Sets this period equal to the other one.
Definition: period.cpp:95
freebusyperiod.h
This file is part of the API for handling calendar data and defines the Period class.
This file is part of the KDE documentation.
Documentation copyright © 1996-2022 The KDE developers.
Generated on Thu Jul 21 2022 00:00:00 by doxygen 1.9.5 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