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

KBlog Client Library

  • sources
  • kde-4.12
  • kdepimlibs
  • kblog
blogmedia.h
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 KBLOG_BLOGMEDIA_H
24 #define KBLOG_BLOGMEDIA_H
25 
26 #include <kblog/kblog_export.h>
27 
28 #include <QtCore/QtAlgorithms>
29 
30 class KUrl;
31 
32 namespace KBlog {
33 
34 class BlogMediaPrivate;
35 
48 class KBLOG_EXPORT BlogMedia
49 {
50 
51  public:
55  explicit BlogMedia();
56 
60  BlogMedia( const BlogMedia &media );
61 
65  virtual ~BlogMedia();
66 
74  QString name() const;
75 
83  void setName( const QString &name );
84 
91  KUrl url() const;
92 
100  void setUrl( const KUrl &url );
101 
108  QString mimetype() const;
109 
116  void setMimetype( const QString &mimetype );
117 
124  QByteArray data() const;
125 
132  void setData( const QByteArray &data );
133 
138  enum Status {
140  New,
142  Created,
144  Error
145  };
146 
153  Status status() const;
154 
162  void setStatus( Status status );
163 
169  QString error() const;
170 
177  void setError( const QString &error );
178 
183  BlogMedia &operator=( const BlogMedia &media );
184 
188  void swap( BlogMedia &other ) {
189  qSwap( this->d_ptr, other.d_ptr );
190  }
191 
192  private:
193  BlogMediaPrivate *d_ptr; //krazy:exclude=dpointer can't constify due to bic and swap being declared inline
194 };
195 
196 } //namespace KBlog
197 
198 #endif
KBlog::BlogMedia
A class that represents a media object on the server.
Definition: blogmedia.h:48
KBlog::BlogMedia::Status
Status
The different possible status.
Definition: blogmedia.h:138
KBlog::BlogMedia::New
Status of freshly constructed media object on the client side.
Definition: blogmedia.h:140
KBlog::BlogMedia::Created
Status of a media object successfully created on the server.
Definition: blogmedia.h:142
KBlog::BlogMedia::swap
void swap(BlogMedia &other)
The swap operator.
Definition: blogmedia.h:188
This file is part of the KDE documentation.
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 22:59:55 by doxygen 1.8.7 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 API Reference

Skip menu "kdepimlibs API Reference"
  • akonadi
  •   contact
  •   kmime
  •   socialutils
  • kabc
  • kalarmcal
  • kblog
  • kcal
  • kcalcore
  • kcalutils
  • kholidays
  • kimap
  • kldap
  • kmbox
  • kmime
  • kpimidentities
  • kpimtextedit
  • kresources
  • ktnef
  • kxmlrpcclient
  • microblog

Search



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