File indexing completed on 2024-06-30 05:51:30
0001 /* 0002 This file is part of the Okteta Kasten Framework, made within the KDE community. 0003 0004 SPDX-FileCopyrightText: 2010, 2011, 2012 Alex Richardson <alex.richardson@gmx.de> 0005 0006 SPDX-License-Identifier: LGPL-2.1-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL 0007 */ 0008 0009 #ifndef KASTEN_SCRIPTVALUECONVERTER_HPP 0010 #define KASTEN_SCRIPTVALUECONVERTER_HPP 0011 0012 class QString; 0013 class QScriptValue; 0014 class ScriptLogger; 0015 template <typename T> class QVector; 0016 class DataInformation; 0017 0018 namespace ScriptValueConverter { 0019 0020 // FIXME remove the = 0 0021 /** If the value is one element */ 0022 DataInformation* convert(const QScriptValue& value, const QString& name, ScriptLogger* logger, 0023 DataInformation* parent = nullptr); 0024 /** If the value is a list of elements or an object with many elements */ 0025 QVector<DataInformation*> convertValues(const QScriptValue& value, ScriptLogger* logger, 0026 DataInformation* parent = nullptr); 0027 0028 } 0029 0030 #endif /* KASTEN_SCRIPTVALUECONVERTER_HPP */