1 | /* |
2 | Copyright (c) 2008 Kevin Krammer <kevin.krammer@gmx.at> |
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 ITEMFETCHSCOPE_P_H |
21 | #define ITEMFETCHSCOPE_P_H |
22 | |
23 | #include <QtCore/QSet> |
24 | #include <QtCore/QString> |
25 | #include <KDE/KDateTime> |
26 | #include "itemfetchscope.h" |
27 | |
28 | namespace Akonadi { |
29 | |
30 | /** |
31 | * @internal |
32 | */ |
33 | class ItemFetchScopePrivate : public QSharedData |
34 | { |
35 | public: |
36 | ItemFetchScopePrivate() |
37 | : mAncestorDepth(ItemFetchScope::None) |
38 | , mFullPayload(false) |
39 | , mAllAttributes(false) |
40 | , mCacheOnly(false) |
41 | , mCheckCachedPayloadPartsOnly(false) |
42 | , mFetchMtime(true) |
43 | , mIgnoreRetrievalErrors(false) |
44 | , mFetchRid(true) |
45 | , mFetchGid(false) |
46 | , mFetchTags(false) |
47 | , mFetchVRefs(false) |
48 | { |
49 | } |
50 | |
51 | ItemFetchScopePrivate(const ItemFetchScopePrivate &other) |
52 | : QSharedData(other) |
53 | { |
54 | mPayloadParts = other.mPayloadParts; |
55 | mAttributes = other.mAttributes; |
56 | mAncestorDepth = other.mAncestorDepth; |
57 | mFullPayload = other.mFullPayload; |
58 | mAllAttributes = other.mAllAttributes; |
59 | mCacheOnly = other.mCacheOnly; |
60 | mCheckCachedPayloadPartsOnly = other.mCheckCachedPayloadPartsOnly; |
61 | mFetchMtime = other.mFetchMtime; |
62 | mIgnoreRetrievalErrors = other.mIgnoreRetrievalErrors; |
63 | mChangedSince = other.mChangedSince; |
64 | mFetchRid = other.mFetchRid; |
65 | mFetchGid = other.mFetchGid; |
66 | mFetchTags = other.mFetchTags; |
67 | mFetchVRefs = other.mFetchVRefs; |
68 | } |
69 | |
70 | public: |
71 | QSet<QByteArray> mPayloadParts; |
72 | QSet<QByteArray> mAttributes; |
73 | ItemFetchScope::AncestorRetrieval mAncestorDepth; |
74 | bool mFullPayload; |
75 | bool mAllAttributes; |
76 | bool mCacheOnly; |
77 | bool mCheckCachedPayloadPartsOnly; |
78 | bool mFetchMtime; |
79 | bool mIgnoreRetrievalErrors; |
80 | KDateTime mChangedSince; |
81 | bool mFetchRid; |
82 | bool mFetchGid; |
83 | bool mFetchTags; |
84 | bool mFetchVRefs; |
85 | }; |
86 | |
87 | } |
88 | |
89 | #endif |
90 | |