23#include "dublincorevocab.h"
26#include <QtCore/QCoreApplication>
27#include <QtCore/QString>
29namespace Syndication {
32class DublinCoreVocab::DublinCoreVocabPrivate
37 PropertyPtr contributor;
41 PropertyPtr description;
43 PropertyPtr identifier;
45 PropertyPtr publisher;
53 static DublinCoreVocab *sSelf;
54 static void cleanupDublinCoreVocab()
60DublinCoreVocab *DublinCoreVocab::DublinCoreVocabPrivate::sSelf = 0;
62DublinCoreVocab::DublinCoreVocab() : d(new DublinCoreVocabPrivate)
64 QString ns = QLatin1String(
"http://purl.org/dc/elements/1.1/");
68 d->contributor = PropertyPtr(
new Property(ns + QLatin1String(
"contributor")) );
69 d->coverage = PropertyPtr(
new Property(ns + QLatin1String(
"coverage")) );
70 d->creator = PropertyPtr(
new Property(ns + QLatin1String(
"creator")) );
71 d->date = PropertyPtr(
new Property(ns + QLatin1String(
"date")) );
72 d->description = PropertyPtr(
new Property(ns + QLatin1String(
"description")) );
73 d->format = PropertyPtr(
new Property(ns + QLatin1String(
"format")) );
74 d->identifier = PropertyPtr(
new Property(ns + QLatin1String(
"identifier")) );
75 d->language = PropertyPtr(
new Property(ns + QLatin1String(
"language")) );
76 d->publisher = PropertyPtr(
new Property(ns + QLatin1String(
"publisher")) );
77 d->relation = PropertyPtr(
new Property(ns + QLatin1String(
"relation")) );
78 d->rights = PropertyPtr(
new Property(ns + QLatin1String(
"rights")) );
79 d->source = PropertyPtr(
new Property(ns + QLatin1String(
"source")) );
80 d->subject = PropertyPtr(
new Property(ns + QLatin1String(
"subject")) );
81 d->title = PropertyPtr(
new Property(ns + QLatin1String(
"title")) );
82 d->type = PropertyPtr(
new Property(ns + QLatin1String(
"type")) );
86DublinCoreVocab::~DublinCoreVocab()
93 static DublinCoreVocabPrivate p;
96 qAddPostRoutine(DublinCoreVocabPrivate::cleanupDublinCoreVocab);
101const QString& DublinCoreVocab::namespaceURI()
const
106PropertyPtr DublinCoreVocab::contributor()
const
108 return d->contributor;
111PropertyPtr DublinCoreVocab::creator()
const
116PropertyPtr DublinCoreVocab::coverage()
const
121PropertyPtr DublinCoreVocab::date()
const
126PropertyPtr DublinCoreVocab::description()
const
128 return d->description;
131PropertyPtr DublinCoreVocab::format()
const
136PropertyPtr DublinCoreVocab::identifier()
const
138 return d->identifier;
141PropertyPtr DublinCoreVocab::language()
const
146PropertyPtr DublinCoreVocab::publisher()
const
151PropertyPtr DublinCoreVocab::relation()
const
156PropertyPtr DublinCoreVocab::rights()
const
161PropertyPtr DublinCoreVocab::source()
const
166PropertyPtr DublinCoreVocab::subject()
const
171PropertyPtr DublinCoreVocab::title()
const
176PropertyPtr DublinCoreVocab::type()
const
Singleton holding RDF class and property constants of the Dublin Core vocabulary.
const QString & namespaceURI() const
the namespace of the Dublin Core vocabulary, http://purl.org/dc/elements/1.1/