File indexing completed on 2024-12-01 12:41:48
0001 /* 0002 This file is part of the syndication library 0003 SPDX-FileCopyrightText: 2006 Frank Osterfeld <osterfeld@kde.org> 0004 0005 SPDX-License-Identifier: LGPL-2.0-or-later 0006 */ 0007 0008 #ifndef SYNDICATION_ATOM_GENERATOR_H 0009 #define SYNDICATION_ATOM_GENERATOR_H 0010 0011 #include <syndication/elementwrapper.h> 0012 0013 class QDomElement; 0014 class QString; 0015 0016 namespace Syndication 0017 { 0018 namespace Atom 0019 { 0020 /** 0021 * Description of the agent used to generate the feed. 0022 * 0023 * @author Frank Osterfeld 0024 */ 0025 class SYNDICATION_EXPORT Generator : public ElementWrapper 0026 { 0027 public: 0028 /** 0029 * default constructor, creates a null generator 0030 */ 0031 Generator(); 0032 0033 /** 0034 * creates a Generator wrapping an atom:generator element. 0035 * @param element a DOM element, should be a atom:generator element 0036 * (although not enforced), otherwise this object will not parse 0037 * anything useful 0038 */ 0039 explicit Generator(const QDomElement &element); 0040 0041 /** 0042 * A URI for the generator (e.g. its homepage) (optional) 0043 */ 0044 Q_REQUIRED_RESULT QString uri() const; 0045 0046 /** 0047 * version of the agent (optional) 0048 */ 0049 Q_REQUIRED_RESULT QString version() const; 0050 0051 /** 0052 * human-readable name of the generator. (optional) 0053 * 0054 * @return generator name as plain text 0055 */ 0056 Q_REQUIRED_RESULT QString name() const; 0057 0058 /** 0059 * a description of this generator for debugging purposes. 0060 * 0061 * @return debug info 0062 */ 0063 Q_REQUIRED_RESULT QString debugInfo() const; 0064 }; 0065 0066 } // namespace Atom 0067 } // namespace Syndication 0068 0069 #endif // SYNDICATION_ATOM_GENERATOR_H