29 #include <QtCore/QList>
30 #include <QtCore/QString>
32 namespace Syndication {
42 info += QLatin1String(
"# Feed begin ######################\n");
44 QString dtitle =
title();
46 info += QLatin1String(
"title: #") + dtitle + QLatin1String(
"#\n");
48 QString dlink =
link();
50 info += QLatin1String(
"link: #") + dlink + QLatin1String(
"#\n");
53 if (!ddescription.isNull())
54 info += QLatin1String(
"description: #") + ddescription + QLatin1String(
"#\n");
57 if (!dcopyright.isNull())
58 info += QLatin1String(
"copyright: #") + dcopyright + QLatin1String(
"#\n");
61 if (!dlanguage.isNull())
62 info += QLatin1String(
"language: #") + dlanguage + QLatin1String(
"#\n");
64 QList<PersonPtr> dauthors =
authors();
65 QList<PersonPtr>::ConstIterator itp = dauthors.constBegin();
66 QList<PersonPtr>::ConstIterator endp = dauthors.constEnd();
68 for ( ; itp != endp; ++itp)
69 info += (*itp)->debugInfo();
72 QList<CategoryPtr>::ConstIterator itc = dcategories.constBegin();
73 QList<CategoryPtr>::ConstIterator endc = dcategories.constEnd();
75 for ( ; itc != endc; ++itc)
76 info += (*itc)->debugInfo();
78 ImagePtr dimage =
image();
80 if (!dimage->isNull())
81 info += dimage->debugInfo();
83 QList<ItemPtr> ditems =
items();
84 QList<ItemPtr>::ConstIterator it = ditems.constBegin();
85 QList<ItemPtr>::ConstIterator end = ditems.constEnd();
87 for ( ; it != end; ++it)
88 info += (*it)->debugInfo();
90 info += QLatin1String(
"# Feed end ########################\n");
virtual QString description() const =0
A description of the feed.
virtual ImagePtr image() const =0
returns an image associated with this item.
virtual ~Feed()
destructor
virtual QList< PersonPtr > authors() const =0
returns a list of persons who created the feed content.
virtual QString title() const =0
The title of the feed.
virtual QList< ItemPtr > items() const =0
A list of items, in the order they were parsed from the feed source.
virtual QString copyright() const =0
returns copyright information about the feed
virtual QString language() const =0
The language used in the feed.
virtual QString link() const =0
returns a link pointing to a website associated with this channel.
virtual QString debugInfo() const
returns a description of the feed for debugging purposes
virtual QList< CategoryPtr > categories() const =0
returns a list of categories this feed is associated with.