File indexing completed on 2024-05-12 15:37:04

0001 /*
0002     Helper class to extract XML encoded Dublin Core metadata
0003 
0004     SPDX-FileCopyrightText: 2018 Stefan BrĂ¼ns <stefan.bruens@rwth-aachen.de>
0005 
0006     SPDX-License-Identifier: LGPL-2.1-or-later
0007 */
0008 
0009 
0010 #ifndef DUBLINCORE_EXTRACTOR_H
0011 #define DUBLINCORE_EXTRACTOR_H
0012 
0013 #include <QDomNode>
0014 
0015 namespace KFileMetaData
0016 {
0017 
0018 class ExtractionResult;
0019 
0020 class DublinCoreExtractor
0021 {
0022 public:
0023     /**
0024       * Extract DC metadata from an XML fragment
0025       *
0026       * Prerequisites:
0027       * - DC element nodes are immediate children to \p fragment
0028       * - The \c QDomDocument has been parsed with enabled namespaceProcessing
0029       *
0030       * \sa QDomDocument::setContent
0031       */
0032     static void extract(ExtractionResult* result, const QDomNode& fragment);
0033 
0034 };
0035 
0036 } // namespace KFileMetaData
0037 
0038 #endif // DUBLINCORE_EXTRACTOR_H
0039