Pimcommon

collectiontypeutil.h
1/*
2 SPDX-FileCopyrightText: 2014-2024 Laurent Montel <montel@kde.org>
3
4 SPDX-License-Identifier: LGPL-2.0-or-later
5
6*/
7
8#pragma once
9#include "pimcommonakonadi_export.h"
10#include <QByteArray>
11#include <QString>
12
13namespace PimCommon
14{
15/**
16 * @brief The CollectionTypeUtil class
17 * @author Laurent Montel <montel@kde.org>
18 */
19class PIMCOMMONAKONADI_EXPORT CollectionTypeUtil
20{
21public:
24
25 static QByteArray kolabFolderType();
26 static QByteArray kolabIncidencesFor();
27 static QByteArray kolabSharedSeen();
28
29 enum FolderContentsType {
30 ContentsTypeMail = 0,
31 ContentsTypeCalendar,
32 ContentsTypeContact,
33 ContentsTypeNote,
34 ContentsTypeTask,
35 ContentsTypeJournal,
36 ContentsTypeConfiguration,
37 ContentsTypeFreebusy,
38 ContentsTypeFile,
39 ContentsTypeLast = ContentsTypeFile
40 };
41
42 enum IncidencesFor {
43 IncForNobody,
44 IncForAdmins,
45 IncForReaders,
46 };
47
48 [[nodiscard]] CollectionTypeUtil::IncidencesFor incidencesForFromString(const QString &string);
49 [[nodiscard]] CollectionTypeUtil::FolderContentsType typeFromKolabName(const QByteArray &name);
50 [[nodiscard]] QString folderContentDescription(CollectionTypeUtil::FolderContentsType type);
51 [[nodiscard]] QByteArray kolabNameFromType(CollectionTypeUtil::FolderContentsType type);
52 [[nodiscard]] QString incidencesForToString(CollectionTypeUtil::IncidencesFor type);
53 [[nodiscard]] CollectionTypeUtil::FolderContentsType contentsTypeFromString(const QString &type);
54 [[nodiscard]] QString typeNameFromKolabType(const QByteArray &type);
55 [[nodiscard]] QString iconNameFromContentsType(CollectionTypeUtil::FolderContentsType type);
56};
57}
The CollectionTypeUtil class.
folderdialogacltab.h
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Fri Jul 26 2024 12:00:34 by doxygen 1.11.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.