akonadi
collection_p.h
00001 /* 00002 Copyright (c) 2006 - 2008 Volker Krause <vkrause@kde.org> 00003 00004 This library is free software; you can redistribute it and/or modify it 00005 under the terms of the GNU Library General Public License as published by 00006 the Free Software Foundation; either version 2 of the License, or (at your 00007 option) any later version. 00008 00009 This library is distributed in the hope that it will be useful, but WITHOUT 00010 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 00011 FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library General Public 00012 License for more details. 00013 00014 You should have received a copy of the GNU Library General Public License 00015 along with this library; see the file COPYING.LIB. If not, write to the 00016 Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 00017 02110-1301, USA. 00018 */ 00019 00020 #ifndef AKONADI_COLLECTION_P_H 00021 #define AKONADI_COLLECTION_P_H 00022 00023 #include "collection.h" 00024 #include "cachepolicy.h" 00025 #include "collectionstatistics.h" 00026 #include "entity_p.h" 00027 00028 #include "qstringlist.h" 00029 00030 using namespace Akonadi; 00031 00035 class Akonadi::CollectionPrivate : public EntityPrivate 00036 { 00037 public: 00038 CollectionPrivate( Collection::Id id = -1 ) : 00039 EntityPrivate( id ), 00040 contentTypesChanged( false ), 00041 cachePolicyChanged( false ) 00042 {} 00043 00044 CollectionPrivate( const CollectionPrivate &other ) : 00045 EntityPrivate( other ) 00046 { 00047 name = other.name; 00048 resource = other.resource; 00049 statistics = other.statistics; 00050 contentTypes = other.contentTypes; 00051 cachePolicy = other.cachePolicy; 00052 contentTypesChanged = other.contentTypesChanged; 00053 cachePolicyChanged = other.cachePolicyChanged; 00054 } 00055 00056 ~CollectionPrivate() 00057 { 00058 } 00059 00060 CollectionPrivate* clone() const 00061 { 00062 return new CollectionPrivate( *this ); 00063 } 00064 00065 void resetChangeLog() 00066 { 00067 contentTypesChanged = false; 00068 cachePolicyChanged = false; 00069 EntityPrivate::resetChangeLog(); 00070 } 00071 00072 static Collection newRoot() 00073 { 00074 Collection rootCollection( 0 ); 00075 QStringList types; 00076 types << Collection::mimeType(); 00077 rootCollection.setContentMimeTypes( types ); 00078 return rootCollection; 00079 } 00080 00081 QString name; 00082 QString resource; 00083 CollectionStatistics statistics; 00084 QStringList contentTypes; 00085 static const Collection root; 00086 CachePolicy cachePolicy; 00087 bool contentTypesChanged; 00088 bool cachePolicyChanged; 00089 }; 00090 00091 #endif
This file is part of the KDE documentation.
Documentation copyright © 1996-2012 The KDE developers.
Generated on Thu Aug 2 2012 15:25:17 by doxygen 1.7.5 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2012 The KDE developers.
Generated on Thu Aug 2 2012 15:25:17 by doxygen 1.7.5 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.