KCalendarCore::FreeBusyPeriod Class
class KCalendarCore::FreeBusyPeriodRepresents a period of time. More...
Header: | #include <KCalendarCore/FreeBusyPeriod> |
CMake: | find_package(KF6 REQUIRED COMPONENTS CalendarCore) target_link_libraries(mytarget PRIVATE KF6::CalendarCore) |
Inherits: | KCalendarCore::Period |
Public Types
enum | FreeBusyType { Free, Busy, BusyUnavailable, BusyTentative, Unknown } |
List |
Public Functions
FreeBusyPeriod() | |
FreeBusyPeriod(const KCalendarCore::Period &period) | |
FreeBusyPeriod(const QDateTime &start, const KCalendarCore::Duration &duration) | |
FreeBusyPeriod(const QDateTime &start, const QDateTime &end) | |
FreeBusyPeriod(const KCalendarCore::FreeBusyPeriod &period) | |
~FreeBusyPeriod() | |
QString | location() const |
void | setLocation(const QString &location) |
void | setSummary(const QString &summary) |
(since 5.0) void | setType(KCalendarCore::FreeBusyPeriod::FreeBusyType type) |
QString | summary() const |
(since 5.0) KCalendarCore::FreeBusyPeriod::FreeBusyType | type() const |
KCalendarCore::FreeBusyPeriod & | operator=(const KCalendarCore::FreeBusyPeriod &other) |
Detailed Description
The period can be defined by either a start time and an end time or by a start time and a duration.
Member Type Documentation
enum FreeBusyPeriod::FreeBusyType
Constant | Value |
---|---|
KCalendarCore::FreeBusyPeriod::Free | 0 |
KCalendarCore::FreeBusyPeriod::Busy | 1 |
KCalendarCore::FreeBusyPeriod::BusyUnavailable | 2 |
KCalendarCore::FreeBusyPeriod::BusyTentative | 3 |
KCalendarCore::FreeBusyPeriod::Unknown | 4 |
FreeBusyPeriod::List
List of periods.
Member Function Documentation
FreeBusyPeriod::FreeBusyPeriod()
Constructs a period without a duration.
FreeBusyPeriod::FreeBusyPeriod(const KCalendarCore::Period &period)
Constructs a period by copying another period object
period is the period to copy
FreeBusyPeriod::FreeBusyPeriod(const QDateTime &start, const KCalendarCore::Duration &duration)
Constructs a period from start and lasting duration.
start is the time when the period starts.
duration is how long the period lasts.
FreeBusyPeriod::FreeBusyPeriod(const QDateTime &start, const QDateTime &end)
Constructs a period from start to end.
start is the time the period begins.
end is the time the period ends.
FreeBusyPeriod::FreeBusyPeriod(const KCalendarCore::FreeBusyPeriod &period)
Constructs a period by copying another period object
period is the period to copy
[noexcept]
FreeBusyPeriod::~FreeBusyPeriod()
Destroys a period.
QString FreeBusyPeriod::location() const
Returns the period location.
See also setLocation().
void FreeBusyPeriod::setLocation(const QString &location)
Sets the period location.
location is the period location string.
See also location().
void FreeBusyPeriod::setSummary(const QString &summary)
Sets the period summary.
summary is the period summary string.
See also summary().
[since 5.0]
void FreeBusyPeriod::setType(KCalendarCore::FreeBusyPeriod::FreeBusyType type)
Sets the free/busy type.
type is the type of free/busy period
This function was introduced in 5.0.
See also type().
QString FreeBusyPeriod::summary() const
Returns the period summary.
See also setSummary().
[since 5.0]
KCalendarCore::FreeBusyPeriod::FreeBusyType FreeBusyPeriod::type() const
Returns free/busy type
This function was introduced in 5.0.
See also setType().
KCalendarCore::FreeBusyPeriod &FreeBusyPeriod::operator=(const KCalendarCore::FreeBusyPeriod &other)
Sets this period equal to the other one.
other is the other period to compare.