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

KBlog Client Library

  • KBlog
  • GData
Signals | Public Member Functions | Protected Member Functions
KBlog::GData Class Reference

#include <gdata.h>

Inheritance diagram for KBlog::GData:
Inheritance graph
[legend]

List of all members.

Signals

void createdComment (const KBlog::BlogPost *post, const KBlog::BlogComment *comment)
void fetchedProfileId (const QString &profileId)
void listedAllComments (const QList< KBlog::BlogComment > &commentsList)
void listedBlogs (const QList< QMap< QString, QString > > &blogsList)
void listedComments (KBlog::BlogPost *post, const QList< KBlog::BlogComment > &comments)
void removedComment (const KBlog::BlogPost *post, const KBlog::BlogComment *comment)

Public Member Functions

 GData (const KUrl &server, QObject *parent=0)
 ~GData ()
virtual void createComment (KBlog::BlogPost *post, KBlog::BlogComment *comment)
void createPost (KBlog::BlogPost *post)
void fetchPost (KBlog::BlogPost *post)
void fetchProfileId ()
QString fullName () const
QString interfaceName () const
virtual void listAllComments ()
virtual void listBlogs ()
virtual void listComments (KBlog::BlogPost *post)
void listRecentPosts (int number)
virtual void listRecentPosts (const QStringList &label=QStringList(), int number=0, const KDateTime &upMinTime=KDateTime(), const KDateTime &upMaxTime=KDateTime(), const KDateTime &pubMinTime=KDateTime(), const KDateTime &pubMaxTime=KDateTime())
void modifyPost (KBlog::BlogPost *post)
QString profileId () const
virtual void removeComment (KBlog::BlogPost *post, KBlog::BlogComment *comment)
void removePost (KBlog::BlogPost *post)
virtual void setFullName (const QString &fullName)
virtual void setProfileId (const QString &pid)

Protected Member Functions

 GData (const KUrl &server, GDataPrivate &dd, QObject *parent=0)

Detailed Description

A class that can be used for access to GData blogs.

The new blogspot.com accounts ( August 2007 ) exclusively support GData API which is a standard based on Atom API. Compared to Blogger 1.0, which is based on Xml-Rpc and less secure, it adds new functionality like titles and comments.

  Blog* myblog = new GData("http://myblogspot.account.com");
  myblog->setProfileId( "2039484587348593945823" ); // can be fetched via fetchProfileId()
  myblog->setBlogId( "1" ); // can be caught by listBlogs()
  myblog->setUsername( "your_email@address.com" );
  myblog->setPassword( "yOuRFuNnYPasSword" );
  KBlog::BlogPost *post = new BlogPost();
  post->setTitle( "This is the title." );
  post->setContent( "Here is some the content..." );
  myblog->createPost( post );
Author:
Christian Weilbach <christian_weilbach@web.de>
Reinhold Kainhofer <reinhold@kainhofer.com>

Definition at line 70 of file gdata.h.


Constructor & Destructor Documentation

GData::GData ( const KUrl &  server,
QObject *  parent = 0 
) [explicit]

Create an object for GData.

Parameters:
serverThe server url for the xmlrpc gateway.
parentThe parent object, inherited from QObject.

Definition at line 46 of file gdata.cpp.

GData::~GData ( )

Destructor.

Definition at line 53 of file gdata.cpp.

KBlog::GData::GData ( const KUrl &  server,
GDataPrivate &  dd,
QObject *  parent = 0 
) [protected]

Overloaded for private inheritance handling.


Member Function Documentation

void GData::createComment ( KBlog::BlogPost *  post,
KBlog::BlogComment *  comment 
) [virtual]

Create a comment on the server.

Parameters:
postThis is the post with its id set correctly.
commentThis is the comment to create.
See also:
BlogPost::setPostId( const QString& )
createdComment( KBlog::BlogPost*, KBlog::BlogComment* )

Definition at line 366 of file gdata.cpp.

void KBlog::GData::createdComment ( const KBlog::BlogPost *  post,
const KBlog::BlogComment *  comment 
) [signal]

This signal is emitted when a comment has been created on the blogging server.

Parameters:
postThis is the corresponding post.
commentThis is the created comment.
See also:
createComment( KBlog::BlogPost *post, KBlog::BlogComment *comment )
void GData::createPost ( KBlog::BlogPost *  post) [virtual]

Create a new post on server.

Parameters:
postThis is send to the server.
See also:
createdPost( KBlog::BlogPost *post )

Implements KBlog::Blog.

Definition at line 267 of file gdata.cpp.

void KBlog::GData::fetchedProfileId ( const QString &  profileId) [signal]

This signal is emitted when the profile id has been fetched.

Parameters:
profileIdThis is the fetched id. On error it is QString()
See also:
fetchProfileId()
void GData::fetchPost ( KBlog::BlogPost *  post) [virtual]

Fetch the Post with a specific id.

Parameters:
postThis is the post with its id set correctly.
See also:
BlogPost::setPostId( const QString& )
fetchedPost( KBlog::BlogPost *post )

Implements KBlog::Blog.

Definition at line 182 of file gdata.cpp.

void GData::fetchProfileId ( )

Get information about the profile from the blog.

Sets the profileId automatically for the blog it is called from.

See also:
setProfileId( const QString& )
void fetchedProfileId( const QString& )

Definition at line 90 of file gdata.cpp.

QString GData::fullName ( ) const

Returns the full name of user of the blog.

See also:
setFullName()

Definition at line 64 of file gdata.cpp.

QString GData::interfaceName ( ) const [virtual]

Returns the of the inherited object.

Implements KBlog::Blog.

Definition at line 58 of file gdata.cpp.

void GData::listAllComments ( ) [virtual]

List the all comments available for this authentication on the server.

See also:
void listedAllComments( const QList<KBlog::BlogComment>& )

Definition at line 171 of file gdata.cpp.

void GData::listBlogs ( ) [virtual]

List the blogs available for this authentication on the server.

See also:
void listedBlogs( const QList<QMap<QString,QString>>& )

Definition at line 100 of file gdata.cpp.

void GData::listComments ( KBlog::BlogPost *  post) [virtual]

List the comments available for this post on the server.

Parameters:
postThe post, which posts should be listed.
See also:
void listedComments( KBlog::BlogPost*, const QList<KBlog::BlogComment>& )

Definition at line 157 of file gdata.cpp.

void KBlog::GData::listedAllComments ( const QList< KBlog::BlogComment > &  commentsList) [signal]

This signal is emitted when a list of all comments has been fetched from the blogging server.

Parameters:
commentsListThe list of comments.
See also:
listAllComments()
void KBlog::GData::listedBlogs ( const QList< QMap< QString, QString > > &  blogsList) [signal]

This signal is emitted when a list of blogs has been fetched from the blogging server.

Parameters:
blogsListThe list of blogs.
See also:
listBlogs()
void KBlog::GData::listedComments ( KBlog::BlogPost *  post,
const QList< KBlog::BlogComment > &  comments 
) [signal]

This signal is emitted when a list of comments has been fetched from the blogging server.

Parameters:
postThis is the corresponding post.
commentsThe list of comments.
See also:
listComments( KBlog::BlogPost* )
void GData::listRecentPosts ( int  number) [virtual]

List recent posts on the server.

The status of the posts will be Fetched.

Parameters:
numberThe number of posts to fetch. The order is newest first.
See also:
void listedPosts( const QList<KBlog::BlogPost>& )
void fetchPost( KBlog::BlogPost* )
BlogPost::Status

Implements KBlog::Blog.

Definition at line 151 of file gdata.cpp.

void GData::listRecentPosts ( const QStringList &  label = QStringList(),
int  number = 0,
const KDateTime &  upMinTime = KDateTime(),
const KDateTime &  upMaxTime = KDateTime(),
const KDateTime &  pubMinTime = KDateTime(),
const KDateTime &  pubMaxTime = KDateTime() 
) [virtual]

List recent posts on the server depending on meta information about the post.

Parameters:
labelThe lables of posts to fetch.
numberThe number of posts to fetch. The order is newest first.
upMinTimeThe oldest upload time of the posts to fetch.
upMaxTimeThe newest upload time of the posts to fetch.
pubMinTimeThe oldest publication time of the posts to fetch.
pubMaxTimeThe newest publication time of the posts to fetch.
See also:
void listedPosts( const QList<KBlog::BlogPost>& )
void fetchPost( KBlog::BlogPost* )

Definition at line 111 of file gdata.cpp.

void GData::modifyPost ( KBlog::BlogPost *  post) [virtual]

Modify a post on server.

Parameters:
postThis is used to send the modified post including the correct id.

Implements KBlog::Blog.

Definition at line 202 of file gdata.cpp.

QString GData::profileId ( ) const

Returns the profile id of the blog.

This is used for rss paths internally.

Returns:
The profile id.
See also:
setProfileId( const QString& )

Definition at line 77 of file gdata.cpp.

void GData::removeComment ( KBlog::BlogPost *  post,
KBlog::BlogComment *  comment 
) [virtual]

Remove a comment from the server.

Parameters:
postThis is the post with its id set correctly.
commentThis is the comment to remove.
See also:
BlogPost::setPostId( const QString& )
removedComment( KBlog::BlogPost*, KBlog::BlogComment* )

Definition at line 420 of file gdata.cpp.

void KBlog::GData::removedComment ( const KBlog::BlogPost *  post,
const KBlog::BlogComment *  comment 
) [signal]

This signal is emitted when a comment has been removed from the blogging server.

Parameters:
postThis is the corresponding post.
commentThis is the removed comment.
See also:
removeComment( KBlog::BlogPost *post, KBlog::BlogComment *comment )
void GData::removePost ( KBlog::BlogPost *  post) [virtual]

Remove a post from the server.

Parameters:
postThis is the post with its id set correctly.
See also:
BlogPost::setPostId( const QString& )
removedPost( KBlog::BlogPost* )

Implements KBlog::Blog.

Definition at line 327 of file gdata.cpp.

void GData::setFullName ( const QString &  fullName) [virtual]

Sets the user's name for the blog.

Username is only the E-Mail address of the user. This is used in createPost and modifyPost.

Parameters:
fullNameis a QString containing the blog username.
See also:
username()
createPost( KBlog::BlogPost* )
modifiyPost( KBlog::BlogPost* )

Definition at line 70 of file gdata.cpp.

void GData::setProfileId ( const QString &  pid) [virtual]

Get the profile's id of the blog.

Parameters:
pidThis is nummeric id.
See also:
profileId()

Definition at line 83 of file gdata.cpp.


The documentation for this class was generated from the following files:
  • gdata.h
  • gdata.cpp
This file is part of the KDE documentation.
Documentation copyright © 1996-2012 The KDE developers.
Generated on Thu May 10 2012 22:16:53 by doxygen 1.8.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

KBlog Client Library

Skip menu "KBlog Client Library"
  • Main Page
  • Namespace List
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • Related Pages

kdepimlibs-4.8.3 API Reference

Skip menu "kdepimlibs-4.8.3 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