1/*
2 This file is part of the kblog library.
3
4 Copyright (c) 2006-2007 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 METAWEBLOG_P_H
24#define METAWEBLOG_P_H
25
26#include "metaweblog.h"
27#include "blogger1_p.h"
28
29#include <kxmlrpcclient/client.h>
30
31namespace KBlog {
32
33class MetaWeblogPrivate : public Blogger1Private
34{
35 public:
36 QMap<QString,QString> mCategories;
37 QList<QMap<QString,QString> > mCategoriesList;
38 unsigned int mCallMediaCounter;
39 QMap<unsigned int,KBlog::BlogMedia*> mCallMediaMap;
40 MetaWeblogPrivate();
41 ~MetaWeblogPrivate();
42 virtual void loadCategories();
43 virtual void saveCategories();
44 virtual void slotListCategories( const QList<QVariant> &result,
45 const QVariant &id );
46 virtual void slotCreateMedia( const QList<QVariant> &result,
47 const QVariant &id );
48 Q_DECLARE_PUBLIC( MetaWeblog )
49
50 QList<QVariant> defaultArgs( const QString &id = QString() );
51 bool readPostFromMap( BlogPost *post, const QMap<QString, QVariant> &postInfo );
52 bool readArgsFromPost( QList<QVariant> *args, const BlogPost &post );
53 QString getCallFromFunction( FunctionToCall type );
54 bool mCatLoaded;
55};
56
57}
58#endif
59