| 1 | // Copyright (C) 2024 The Qt Company Ltd. |
| 2 | // SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only |
| 3 | |
| 4 | #ifndef QTPROTOBUFSERIALIZERHELPERS_P_H |
| 5 | #define QTPROTOBUFSERIALIZERHELPERS_P_H |
| 6 | |
| 7 | // |
| 8 | // W A R N I N G |
| 9 | // ------------- |
| 10 | // |
| 11 | // This file is not part of the Qt API. It exists for the convenience |
| 12 | // of the Qt Protobuf API. This header file may change from |
| 13 | // version to version without notice, or even be removed. |
| 14 | // |
| 15 | // We mean it. |
| 16 | // |
| 17 | |
| 18 | #include <QtProtobuf/qtprotobufexports.h> |
| 19 | |
| 20 | #include <QtCore/qtconfigmacros.h> |
| 21 | |
| 22 | QT_BEGIN_NAMESPACE |
| 23 | |
| 24 | class QVariant; |
| 25 | class QProtobufMessage; |
| 26 | struct QMetaObject; |
| 27 | |
| 28 | namespace QtProtobufPrivate { |
| 29 | struct QProtobufFieldInfo; |
| 30 | } |
| 31 | |
| 32 | namespace QtProtobufSerializerHelpers { |
| 33 | QVariant messageProperty(const QProtobufMessage *message, |
| 34 | const QtProtobufPrivate::QProtobufFieldInfo &fieldInfo, |
| 35 | bool allowInitialize = false); |
| 36 | bool setMessageProperty(QProtobufMessage *message, |
| 37 | const QtProtobufPrivate::QProtobufFieldInfo &fieldInfo, |
| 38 | const QVariant &value); |
| 39 | bool setMessageProperty(QProtobufMessage *message, |
| 40 | const QtProtobufPrivate::QProtobufFieldInfo &fieldInfo, QVariant &&value); |
| 41 | |
| 42 | const QMetaObject *messageMetaObject(const QProtobufMessage *message); |
| 43 | } |
| 44 | |
| 45 | QT_END_NAMESPACE |
| 46 | |
| 47 | #endif // QTPROTOBUFSERIALIZERHELPERS_P_H |
| 48 | |