| 1 | /* |
| 2 | This file is part of the syndication library |
| 3 | SPDX-FileCopyrightText: 2006 Frank Osterfeld <osterfeld@kde.org> |
| 4 | |
| 5 | SPDX-License-Identifier: LGPL-2.0-or-later |
| 6 | */ |
| 7 | |
| 8 | #ifndef SYNDICATION_RDF_RDFVOCAB_H |
| 9 | #define SYNDICATION_RDF_RDFVOCAB_H |
| 10 | |
| 11 | #include <QSharedPointer> |
| 12 | |
| 13 | #include "../syndication_export.h" |
| 14 | |
| 15 | #include <memory> |
| 16 | |
| 17 | class QString; |
| 18 | |
| 19 | namespace Syndication |
| 20 | { |
| 21 | namespace RDF |
| 22 | { |
| 23 | class Property; |
| 24 | typedef QSharedPointer<Property> PropertyPtr; |
| 25 | class Resource; |
| 26 | typedef QSharedPointer<Resource> ResourcePtr; |
| 27 | |
| 28 | /*! |
| 29 | * singleton holding RDF vocabulary, expressed as RDF. |
| 30 | */ |
| 31 | class RDFVocab |
| 32 | { |
| 33 | public: |
| 34 | /*! |
| 35 | * returns the singleton instance |
| 36 | */ |
| 37 | static RDFVocab *self(); |
| 38 | |
| 39 | /*! |
| 40 | * destructor |
| 41 | */ |
| 42 | ~RDFVocab(); |
| 43 | |
| 44 | /*! |
| 45 | * the RDF namespace, which is |
| 46 | * http://www.w3.org/1999/02/22-rdf-syntax-ns# |
| 47 | */ |
| 48 | QString namespaceURI(); |
| 49 | |
| 50 | /*! |
| 51 | * the sequence type |
| 52 | */ |
| 53 | ResourcePtr seq(); |
| 54 | |
| 55 | /*! |
| 56 | * the rdf:type property (A rdf:type B means A is instance of B) |
| 57 | */ |
| 58 | PropertyPtr type(); |
| 59 | |
| 60 | /*! |
| 61 | * the rdf:li property, used for list items in RDF containers (like |
| 62 | * rdf:seq) |
| 63 | */ |
| 64 | PropertyPtr li(); |
| 65 | |
| 66 | private: |
| 67 | RDFVocab(); |
| 68 | Q_DISABLE_COPY(RDFVocab) |
| 69 | class RDFVocabPrivate; |
| 70 | std::unique_ptr<RDFVocabPrivate> const d; |
| 71 | }; |
| 72 | |
| 73 | } // namespace RDF |
| 74 | } // namespace Syndication |
| 75 | |
| 76 | #endif // SYNDICATION_RDF_RDFVOCAB_H |
| 77 | |