1 | /* |
2 | This file is part of the kblog library. |
3 | |
4 | Copyright (c) 2007-2009 Christian Weilbach <christian_weilbach@web.de> |
5 | Copyright (c) 2007 Mike McQuaid <mike@mikemcquaid.com> |
6 | |
7 | This library is free software; you can redistribute it and/or |
8 | modify it under the terms of the GNU Library General Public |
9 | License as published by the Free Software Foundation; either |
10 | version 2 of the License, or (at your option) any later version. |
11 | |
12 | This library is distributed in the hope that it will be useful, |
13 | but WITHOUT ANY WARRANTY; without even the implied warranty of |
14 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
15 | Library General Public License for more details. |
16 | |
17 | You should have received a copy of the GNU Library General Public License |
18 | along with this library; see the file COPYING.LIB. If not, write to |
19 | the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, |
20 | Boston, MA 02110-1301, USA. |
21 | */ |
22 | |
23 | #ifndef MOVABLETYPE_P_H |
24 | #define MOVABLETYPE_P_H |
25 | |
26 | #include "movabletype.h" |
27 | #include "metaweblog_p.h" |
28 | |
29 | #include <kxmlrpcclient/client.h> |
30 | class KJob; |
31 | class QByteArray; |
32 | |
33 | namespace KIO |
34 | { |
35 | class Job; |
36 | } |
37 | |
38 | namespace KBlog { |
39 | |
40 | class MovableTypePrivate : public MetaWeblogPrivate |
41 | { |
42 | public: |
43 | QMap<KJob *,QByteArray> mSetPostCategoriesBuffer; |
44 | QMap<KJob *, QString> mSetPostCategoriesMap; |
45 | MovableTypePrivate(); |
46 | virtual ~MovableTypePrivate(); |
47 | virtual void slotListTrackBackPings( const QList<QVariant> &result, |
48 | const QVariant &id ); |
49 | void slotCreatePost( const QList<QVariant> &, const QVariant & ); |
50 | void slotFetchPost( const QList<QVariant> &, const QVariant & ); |
51 | void slotModifyPost( const QList<QVariant> &, const QVariant & ); |
52 | void slotSetPostCategories(const QList<QVariant>&,const QVariant&); |
53 | void slotGetPostCategories(const QList<QVariant>&,const QVariant&); |
54 | void slotTriggerCreatePost(); |
55 | void slotTriggerModifyPost(); |
56 | void slotTriggerFetchPost(); |
57 | Q_DECLARE_PUBLIC( MovableType ) |
58 | |
59 | QList<QVariant> defaultArgs( const QString &id = QString() ); |
60 | virtual void setPostCategories( BlogPost *post, bool publishAfterCategories ); |
61 | bool readPostFromMap( BlogPost *post, const QMap<QString, QVariant> &postInfo ); |
62 | bool readArgsFromPost( QList<QVariant> *args, const BlogPost &post ); |
63 | QMap<int,bool> mPublishAfterCategories; |
64 | QList<BlogPost*> mCreatePostCache; |
65 | QList<BlogPost*> mModifyPostCache; |
66 | QList<BlogPost*> mFetchPostCache; |
67 | QList<BlogPost*> mSilentCreationList; |
68 | }; |
69 | |
70 | } |
71 | |
72 | #endif |
73 | |