File indexing completed on 2024-12-29 04:51:01
0001 /* 0002 SPDX-FileCopyrightText: 2017-2021 Volker Krause <vkrause@kde.org> 0003 0004 SPDX-License-Identifier: LGPL-2.0-or-later 0005 */ 0006 0007 #pragma once 0008 0009 #include <KItinerary/ExtractorDocumentProcessor> 0010 0011 namespace KItinerary { 0012 0013 /** Processor for raw JSON-LD data. 0014 * This is simply a pass-through for JSON data, so the using code can apply post-processing to that. 0015 */ 0016 class JsonLdDocumentProcessor : public ExtractorDocumentProcessor 0017 { 0018 public: 0019 bool canHandleData(const QByteArray &encodedData, QStringView fileName) const override; 0020 ExtractorDocumentNode createNodeFromData(const QByteArray &encodedData) const override; 0021 void preExtract(ExtractorDocumentNode &node, const ExtractorEngine *engine) const override; 0022 }; 0023 0024 } 0025