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

syndication/rss2

  • syndication
  • rss2
source.cpp
1 /*
2  * This file is part of the syndication library
3  *
4  * Copyright (C) 2005 Frank Osterfeld <osterfeld@kde.org>
5  *
6  * This library is free software; you can redistribute it and/or
7  * modify it under the terms of the GNU Library General Public
8  * License as published by the Free Software Foundation; either
9  * version 2 of the License, or (at your option) any later version.
10  *
11  * This library is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14  * Library General Public License for more details.
15  *
16  * You should have received a copy of the GNU Library General Public License
17  * along with this library; see the file COPYING.LIB. If not, write to
18  * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
19  * Boston, MA 02110-1301, USA.
20  *
21  */
22 
23 #include "source.h"
24 #include "tools.h"
25 
26 #include <QtCore/QString>
27 
28 namespace Syndication {
29 namespace RSS2 {
30 
31 Source::Source() : ElementWrapper()
32 {
33 }
34 
35 Source::Source(const QDomElement& element) : ElementWrapper(element)
36 {
37 }
38 
39 QString Source::source() const
40 {
41  return text();
42 }
43 
44 QString Source::url() const
45 {
46  return attribute(QLatin1String("url"));
47 }
48 
49 QString Source::debugInfo() const
50 {
51  QString info;
52  info += QLatin1String("### Source: ###################\n");
53  if (!source().isNull())
54  info += QLatin1String("source: #") + source() + QLatin1String("#\n");
55  if (!url().isNull())
56  info += QLatin1String("url: #") + url() + QLatin1String("#\n");
57  info += QLatin1String("### Source end ################\n");
58  return info;
59 }
60 
61 
62 } // namespace RSS2
63 } // namespace Syndication
64 
Syndication::RSS2::Source::debugInfo
QString debugInfo() const
Returns a description of the object for debugging purposes.
Definition: source.cpp:49
Syndication::RSS2::Source::url
QString url() const
Required attribute, links to the XMLization of the source.
Definition: source.cpp:44
Syndication::RSS2::Source::Source
Source()
Default constructor, creates a null object, for which isNull() is true.
Definition: source.cpp:31
Syndication::RSS2::Source::source
QString source() const
The name of the RSS channel that the item came from, derived from its &lt;title&gt;.
Definition: source.cpp:39
This file is part of the KDE documentation.
Documentation copyright © 1996-2013 The KDE developers.
Generated on Tue Nov 26 2013 09:02:48 by doxygen 1.8.5 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

syndication/rss2

Skip menu "syndication/rss2"
  • Main Page
  • Namespace List
  • Namespace Members
  • Alphabetical List
  • Class List
  • Class Members
  • File List

kdepimlibs-4.11.3 API Reference

Skip menu "kdepimlibs-4.11.3 API Reference"
  • akonadi
  •   contact
  •   kmime
  •   socialutils
  • kabc
  • kalarmcal
  • kblog
  • kcal
  • kcalcore
  • kcalutils
  • kholidays
  • kimap
  • kioslave
  •   imap4
  •   mbox
  •   nntp
  • kldap
  • kmbox
  • kmime
  • kontactinterface
  • kpimidentities
  • kpimtextedit
  • 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