Kgapi

calendar.h
1 /*
2  * This file is part of LibKGAPI library
3  *
4  * SPDX-FileCopyrightText: 2013 Daniel Vrátil <[email protected]>
5  *
6  * SPDX-License-Identifier: LGPL-2.1-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL
7  */
8 
9 #ifndef LIBKGAPI2_CALENDAR_H
10 #define LIBKGAPI2_CALENDAR_H
11 
12 #include "object.h"
13 #include "types.h"
14 #include "kgapicalendar_export.h"
15 
16 #include <QColor>
17 #include <QScopedPointer>
18 
19 namespace KGAPI2
20 {
21 
22 /**
23  * @brief An object that represents a Google calendar.
24  *
25  * @author Daniel Vrátil <[email protected]>
26  * @since 0.1
27  */
28 class KGAPICALENDAR_EXPORT Calendar: public KGAPI2::Object
29 {
30 
31  public:
32  /**
33  * @brief Constructor
34  */
35  explicit Calendar();
36 
37  /**
38  * @brief Copy constructor
39  */
40  Calendar(const Calendar &other);
41 
42  /**
43  * @brief Destructor
44  */
45  ~Calendar() override;
46 
47  bool operator==(const Calendar &other) const;
48 
49  /**
50  * @brief Returns uID of the calendar.
51  */
52  QString uid() const;
53 
54  /**
55  * @brief Sets UID of the calendar.
56  *
57  * @param uid
58  */
59  void setUid(const QString &uid);
60 
61  /**
62  * @brief Returns calendar title (name).
63  */
64  QString title() const;
65 
66  /**
67  * @brief Sets a calendar title (name).
68  *
69  * @param title
70  */
71  void setTitle(const QString &title);
72 
73  /**
74  * @brief Returns detailed description of the calendar.
75  */
76  QString details() const;
77 
78  /**
79  * @brief Sets detailed description of a calendar.
80  *
81  * @param details
82  */
83  void setDetails(const QString &details);
84 
85  /**
86  * @brief Returns geographic location of the calendar.
87  */
88  QString location() const;
89 
90  /**
91  * @brief Sets geographic location of the calendar.
92  *
93  * @param location
94  */
95  void setLocation(const QString &location);
96 
97  /**
98  * @brief Returns timezone of the calendar.
99  */
100  QString timezone() const;
101 
102  /**
103  * @brief Sets timezone of the calendar.
104  *
105  * @param timezone
106  */
107  void setTimezone(const QString &timezone);
108 
109  /**
110  * @brief Returns whether calendar is editable or read-only.
111  */
112  bool editable() const;
113 
114  /**
115  * @brief Sets calendar to read-only or editable.
116  *
117  * @param editable
118  */
119  void setEditable(const bool editable);
120 
121  /**
122  * @brief Sets default reminders for all new events in the calendar.
123  *
124  * @param reminders
125  */
126  void setDefaultReminders(const RemindersList &reminders);
127 
128  /**
129  * @brief Adds a default reminder for all events in the calendar.
130  *
131  * @param reminder
132  */
133  void addDefaultReminer(const ReminderPtr &reminder);
134 
135  /**
136  * @brief Returns default reminders for all events in the calendar.
137  */
138  RemindersList defaultReminders() const;
139 
140  /**
141  * @brief Returns calendar background color.
142  *
143  * @since 2.1
144  */
145  QColor backgroundColor() const;
146 
147  /**
148  * @brief Sets calendar background color.
149  *
150  * @param color
151  *
152  * @since 2.1
153  */
154  void setBackgroundColor(const QColor &color);
155 
156  /**
157  * @brief Returns calendar foreground color.
158  *
159  * @since 2.1
160  */
161  QColor foregroundColor() const;
162 
163  /**
164  * @brief Sets calendar foreground color
165  *
166  * @param color
167  *
168  * @since 2.1
169  */
170  void setForegroundColor(const QColor &color);
171 
172  protected:
173  class Private;
174  QScopedPointer<Private> const d;
175 
176 };
177 
178 } // namespace KGAPI2
179 
180 #endif // LIBKGAPI2_CALENDAR_H
Base class for all objects.
Definition: object.h:31
A job to fetch a single map tile described by a StaticMapUrl.
Definition: blog.h:16
An object that represents a Google calendar.
Definition: calendar.h:28
This file is part of the KDE documentation.
Documentation copyright © 1996-2021 The KDE developers.
Generated on Wed Mar 3 2021 00:10:03 by doxygen 1.8.11 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.