• Skip to content
  • Skip to link menu
  • KDE API Reference
  • kdepimlibs-4.9.4 API Reference
  • KDE Home
  • Contact Us
 

akonadi

  • akonadi
collection_p.h
1 /*
2  Copyright (c) 2006 - 2008 Volker Krause <vkrause@kde.org>
3 
4  This library is free software; you can redistribute it and/or modify it
5  under the terms of the GNU Library General Public License as published by
6  the Free Software Foundation; either version 2 of the License, or (at your
7  option) any later version.
8 
9  This library is distributed in the hope that it will be useful, but WITHOUT
10  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
11  FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library General Public
12  License for more details.
13 
14  You should have received a copy of the GNU Library General Public License
15  along with this library; see the file COPYING.LIB. If not, write to the
16  Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
17  02110-1301, USA.
18 */
19 
20 #ifndef AKONADI_COLLECTION_P_H
21 #define AKONADI_COLLECTION_P_H
22 
23 #include "collection.h"
24 #include "cachepolicy.h"
25 #include "collectionstatistics.h"
26 #include "entity_p.h"
27 
28 #include "qstringlist.h"
29 
30 using namespace Akonadi;
31 
35 class Akonadi::CollectionPrivate : public EntityPrivate
36 {
37  public:
38  CollectionPrivate( Collection::Id id = -1 ) :
39  EntityPrivate( id ),
40  contentTypesChanged( false ),
41  cachePolicyChanged( false )
42  {}
43 
44  CollectionPrivate( const CollectionPrivate &other ) :
45  EntityPrivate( other )
46  {
47  name = other.name;
48  resource = other.resource;
49  statistics = other.statistics;
50  contentTypes = other.contentTypes;
51  cachePolicy = other.cachePolicy;
52  contentTypesChanged = other.contentTypesChanged;
53  cachePolicyChanged = other.cachePolicyChanged;
54  }
55 
56  ~CollectionPrivate()
57  {
58  }
59 
60  CollectionPrivate* clone() const
61  {
62  return new CollectionPrivate( *this );
63  }
64 
65  void resetChangeLog()
66  {
67  contentTypesChanged = false;
68  cachePolicyChanged = false;
69  EntityPrivate::resetChangeLog();
70  }
71 
72  static Collection newRoot()
73  {
74  Collection rootCollection( 0 );
75  QStringList types;
76  types << Collection::mimeType();
77  rootCollection.setContentMimeTypes( types );
78  return rootCollection;
79  }
80 
81  QString name;
82  QString resource;
83  CollectionStatistics statistics;
84  QStringList contentTypes;
85  static const Collection root;
86  CachePolicy cachePolicy;
87  bool contentTypesChanged;
88  bool cachePolicyChanged;
89 };
90 
91 #endif
This file is part of the KDE documentation.
Documentation copyright © 1996-2012 The KDE developers.
Generated on Mon Dec 10 2012 13:48:07 by doxygen 1.8.1.2 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

akonadi

Skip menu "akonadi"
  • Main Page
  • Namespace List
  • Namespace Members
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • Modules
  • Related Pages

kdepimlibs-4.9.4 API Reference

Skip menu "kdepimlibs-4.9.4 API Reference"
  • akonadi
  •   contact
  •   kmime
  • kabc
  • kalarmcal
  • kblog
  • kcal
  • kcalcore
  • kcalutils
  • kholidays
  • kimap
  • kioslave
  •   imap4
  •   mbox
  •   nntp
  • kldap
  • kmbox
  • kmime
  • kontactinterface
  • kpimidentities
  • kpimtextedit
  •   richtextbuilders
  • kpimutils
  • kresources
  • ktnef
  • kxmlrpcclient
  • mailtransport
  • microblog
  • qgpgme
  • syndication
  •   atom
  •   rdf
  •   rss2
Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal