Syndication
8#include "itemrdfimpl.h"
13#include <personimpl.h>
14#include <rdf/dublincore.h>
15#include <rdf/property.h>
16#include <rdf/resource.h>
17#include <rdf/resourcewrapper.h>
18#include <rdf/statement.h>
31ItemRDFImpl::ItemRDFImpl(
const Syndication::RDF::Item &item)
38 return m_item.title();
48 return m_item.description();
53 return m_item.encodedContent();
60 const QStringList people = m_item.dc().creators() + m_item.dc().contributors();
62 for (
const auto &person : people) {
63 PersonPtr ptr = personFromString(person);
74 return m_item.dc().language();
79 if (!m_item.resource()->isAnon()) {
80 return m_item.resource()->uri();
82 return QLatin1String(
"hash:") + calcMD5Sum(title() + description() + link() + content());
86time_t ItemRDFImpl::datePublished()
const
88 return m_item.dc().date();
91time_t ItemRDFImpl::dateUpdated()
const
93 return m_item.dc().date();
108int ItemRDFImpl::commentsCount()
const
111 QString cstr = m_item.resource()->property(prop)->asString();
113 int comments = cstr.
toInt(&ok);
114 return ok ? comments : -1;
126 return m_item.resource()->property(prop)->asString();
132 return m_item.resource()->property(prop)->asString();
135Syndication::SpecificItemPtr ItemRDFImpl::specificItem()
const
137 return Syndication::SpecificItemPtr(
new Syndication::RDF::Item(m_item));
a property is node type that represents properties of things, like "name" is a property of a person,...
QString slashNamespace()
"slash" namespace http://purl.org/rss/1.0/modules/slash/
QString commentApiNamespace()
wellformedweb.org's RSS namespace for comment functionality "http://wellformedweb....
void append(QList< T > &&value)
int toInt(bool *ok, int base) const const
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Sat Apr 27 2024 22:07:57 by
doxygen 1.10.0 written
by
Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.