1 /* 2 * SPDX-FileCopyrightText: 2012 Christian Mollekopf <mollekopf@kolabsys.com> 3 * 4 * SPDX-License-Identifier: LGPL-3.0-or-later 5 */ 6 7 #pragma once 8 9 #include <kolab_export.h> 10 #include <string> 11 12 namespace Kolab 13 { 14 enum FolderType { 15 MailType = 0, 16 ContactType, 17 EventType, 18 TaskType, 19 JournalType, 20 NoteType, 21 ConfigurationType, 22 FreebusyType, 23 FileType, 24 LastType, 25 }; 26 27 /** 28 * Returns the FolderType from a KOLAB_FOLDER_TYPE_* folder type string 29 */ 30 KOLAB_EXPORT FolderType folderTypeFromString(const std::string &folderTypeName); 31 /** 32 * Returns the annotation string for a folder 33 */ 34 KOLAB_EXPORT std::string folderAnnotation(FolderType type, bool isDefault = false); 35 /** 36 * Guesses the folder type from a user visible string 37 */ 38 KOLAB_EXPORT FolderType guessFolderTypeFromName(const std::string &name); 39 40 /** 41 * Returns a folder name for a type 42 */ 43 KOLAB_EXPORT std::string nameForFolderType(FolderType type); 44 } 45 46