#ifndef REP_FRONTEND_H
#define REP_FRONTEND_H

// This is an autogenerated file.
// Do not edit this file, any changes made will be lost the next time it is generated.

#include <QtCore/qobject.h>
#include <QtCore/qdatastream.h>
#include <QtCore/qvariant.h>
#include <QtCore/qmetatype.h>

#include <QtRemoteObjects/qremoteobjectnode.h>
#include <QtRemoteObjects/qremoteobjectpendingcall.h>
#include <QtRemoteObjects/qremoteobjectreplica.h>
#include <QtRemoteObjects/qremoteobjectsource.h>

#include "frontend/frontendtypes.h"

class FrontendReplica : public QRemoteObjectReplica
{
    Q_OBJECT
    Q_CLASSINFO(QCLASSINFO_REMOTEOBJECT_TYPE, "Frontend")
    Q_CLASSINFO(QCLASSINFO_REMOTEOBJECT_SIGNATURE, "8e55f9a1328c0af1d084e5a8d6f54c5daec1cb63")
    Q_PROPERTY(qint32 ActiveSceneIndex READ ActiveSceneIndex NOTIFY ActiveSceneIndexChanged)
    Q_PROPERTY(QList<SceneInfo> Scenes READ Scenes NOTIFY ScenesChanged)
    Q_PROPERTY(QList<DeviceInfo> Devices READ Devices NOTIFY DevicesChanged)
    Q_PROPERTY(QList<BridgeInfo> Bridges READ Bridges NOTIFY BridgesChanged)
    Q_PROPERTY(RazerInfo Razer READ Razer NOTIFY RazerChanged)
    Q_PROPERTY(bool IsRunning READ IsRunning NOTIFY IsRunningChanged)

public:
    FrontendReplica() : QRemoteObjectReplica() { initialize(); }
    static void registerMetatypes()
    {
        static bool initialized = false;
        if (initialized)
            return;
        initialized = true;
        qRegisterMetaType<QList<BridgeInfo>>();
        qRegisterMetaTypeStreamOperators<QList<BridgeInfo>>();
        qRegisterMetaType<QList<SceneInfo>>();
        qRegisterMetaTypeStreamOperators<QList<SceneInfo>>();
        qRegisterMetaType<RazerInfo>();
        qRegisterMetaTypeStreamOperators<RazerInfo>();
        qRegisterMetaType<QList<DeviceInfo>>();
        qRegisterMetaTypeStreamOperators<QList<DeviceInfo>>();

    }

private:
    FrontendReplica(QRemoteObjectNode *node, const QString &name = QString())
        : QRemoteObjectReplica(ConstructWithNode)
    {
        initializeNode(node, name);
    }

    void initialize() override
    {
        FrontendReplica::registerMetatypes();
        QVariantList properties;
        properties.reserve(6);
        properties << QVariant::fromValue(qint32());
        properties << QVariant::fromValue(QList<SceneInfo>());
        properties << QVariant::fromValue(QList<DeviceInfo>());
        properties << QVariant::fromValue(QList<BridgeInfo>());
        properties << QVariant::fromValue(RazerInfo());
        properties << QVariant::fromValue(bool());
        setProperties(properties);
    }

public:
    virtual ~FrontendReplica() {}

    qint32 ActiveSceneIndex() const
    {
        const QVariant variant = propAsVariant(0);
        if (!variant.canConvert<qint32>()) {
            qWarning() << "QtRO cannot convert the property ActiveSceneIndex to type qint32";
        }
        return variant.value<qint32 >();
    }

    QList<SceneInfo> Scenes() const
    {
        const QVariant variant = propAsVariant(1);
        if (!variant.canConvert<QList<SceneInfo>>()) {
            qWarning() << "QtRO cannot convert the property Scenes to type QList<SceneInfo>";
        }
        return variant.value<QList<SceneInfo> >();
    }

    QList<DeviceInfo> Devices() const
    {
        const QVariant variant = propAsVariant(2);
        if (!variant.canConvert<QList<DeviceInfo>>()) {
            qWarning() << "QtRO cannot convert the property Devices to type QList<DeviceInfo>";
        }
        return variant.value<QList<DeviceInfo> >();
    }

    QList<BridgeInfo> Bridges() const
    {
        const QVariant variant = propAsVariant(3);
        if (!variant.canConvert<QList<BridgeInfo>>()) {
            qWarning() << "QtRO cannot convert the property Bridges to type QList<BridgeInfo>";
        }
        return variant.value<QList<BridgeInfo> >();
    }

    RazerInfo Razer() const
    {
        const QVariant variant = propAsVariant(4);
        if (!variant.canConvert<RazerInfo>()) {
            qWarning() << "QtRO cannot convert the property Razer to type RazerInfo";
        }
        return variant.value<RazerInfo >();
    }

    bool IsRunning() const
    {
        const QVariant variant = propAsVariant(5);
        if (!variant.canConvert<bool>()) {
            qWarning() << "QtRO cannot convert the property IsRunning to type bool";
        }
        return variant.value<bool >();
    }


Q_SIGNALS:
    void ActiveSceneIndexChanged(qint32 ActiveSceneIndex);
    void ScenesChanged(QList<SceneInfo> Scenes);
    void DevicesChanged(QList<DeviceInfo> Devices);
    void BridgesChanged(QList<BridgeInfo> Bridges);
    void RazerChanged(RazerInfo Razer);
    void IsRunningChanged(bool IsRunning);

public Q_SLOTS:
    void pushActiveSceneIndex(qint32 ActiveSceneIndex)
    {
        static int __repc_index = FrontendReplica::staticMetaObject.indexOfSlot("pushActiveSceneIndex(qint32)");
        QVariantList __repc_args;
        __repc_args << QVariant::fromValue(ActiveSceneIndex);
        send(QMetaObject::InvokeMetaMethod, __repc_index, __repc_args);
    }
    void pushScenes(QList<SceneInfo> Scenes)
    {
        static int __repc_index = FrontendReplica::staticMetaObject.indexOfSlot("pushScenes(QList<SceneInfo>)");
        QVariantList __repc_args;
        __repc_args << QVariant::fromValue(Scenes);
        send(QMetaObject::InvokeMetaMethod, __repc_index, __repc_args);
    }
    void pushDevices(QList<DeviceInfo> Devices)
    {
        static int __repc_index = FrontendReplica::staticMetaObject.indexOfSlot("pushDevices(QList<DeviceInfo>)");
        QVariantList __repc_args;
        __repc_args << QVariant::fromValue(Devices);
        send(QMetaObject::InvokeMetaMethod, __repc_index, __repc_args);
    }
    void pushBridges(QList<BridgeInfo> Bridges)
    {
        static int __repc_index = FrontendReplica::staticMetaObject.indexOfSlot("pushBridges(QList<BridgeInfo>)");
        QVariantList __repc_args;
        __repc_args << QVariant::fromValue(Bridges);
        send(QMetaObject::InvokeMetaMethod, __repc_index, __repc_args);
    }
    void pushRazer(RazerInfo Razer)
    {
        static int __repc_index = FrontendReplica::staticMetaObject.indexOfSlot("pushRazer(RazerInfo)");
        QVariantList __repc_args;
        __repc_args << QVariant::fromValue(Razer);
        send(QMetaObject::InvokeMetaMethod, __repc_index, __repc_args);
    }
    void pushIsRunning(bool IsRunning)
    {
        static int __repc_index = FrontendReplica::staticMetaObject.indexOfSlot("pushIsRunning(bool)");
        QVariantList __repc_args;
        __repc_args << QVariant::fromValue(IsRunning);
        send(QMetaObject::InvokeMetaMethod, __repc_index, __repc_args);
    }

private:
    friend class QT_PREPEND_NAMESPACE(QRemoteObjectNode);
};

#if (QT_VERSION < QT_VERSION_CHECK(5, 5, 0))
#endif


class FrontendSource : public QObject
{
    Q_OBJECT
    Q_CLASSINFO(QCLASSINFO_REMOTEOBJECT_TYPE, "Frontend")
    Q_CLASSINFO(QCLASSINFO_REMOTEOBJECT_SIGNATURE, "8e55f9a1328c0af1d084e5a8d6f54c5daec1cb63")
    Q_PROPERTY(qint32 ActiveSceneIndex READ ActiveSceneIndex WRITE setActiveSceneIndex NOTIFY ActiveSceneIndexChanged)
    Q_PROPERTY(QList<SceneInfo> Scenes READ Scenes WRITE setScenes NOTIFY ScenesChanged)
    Q_PROPERTY(QList<DeviceInfo> Devices READ Devices WRITE setDevices NOTIFY DevicesChanged)
    Q_PROPERTY(QList<BridgeInfo> Bridges READ Bridges WRITE setBridges NOTIFY BridgesChanged)
    Q_PROPERTY(RazerInfo Razer READ Razer WRITE setRazer NOTIFY RazerChanged)
    Q_PROPERTY(bool IsRunning READ IsRunning WRITE setIsRunning NOTIFY IsRunningChanged)

public:
    explicit FrontendSource(QObject *parent = nullptr) : QObject(parent)
    {
        qRegisterMetaType<QList<BridgeInfo>>();
        qRegisterMetaTypeStreamOperators<QList<BridgeInfo>>();
        qRegisterMetaType<QList<SceneInfo>>();
        qRegisterMetaTypeStreamOperators<QList<SceneInfo>>();
        qRegisterMetaType<RazerInfo>();
        qRegisterMetaTypeStreamOperators<RazerInfo>();
        qRegisterMetaType<QList<DeviceInfo>>();
        qRegisterMetaTypeStreamOperators<QList<DeviceInfo>>();

    }

public:
    virtual ~FrontendSource() {}

    virtual qint32 ActiveSceneIndex() const = 0;
    virtual QList<SceneInfo> Scenes() const = 0;
    virtual QList<DeviceInfo> Devices() const = 0;
    virtual QList<BridgeInfo> Bridges() const = 0;
    virtual RazerInfo Razer() const = 0;
    virtual bool IsRunning() const = 0;
    virtual void setActiveSceneIndex(qint32 ActiveSceneIndex) = 0;
    virtual void setScenes(QList<SceneInfo> Scenes) = 0;
    virtual void setDevices(QList<DeviceInfo> Devices) = 0;
    virtual void setBridges(QList<BridgeInfo> Bridges) = 0;
    virtual void setRazer(RazerInfo Razer) = 0;
    virtual void setIsRunning(bool IsRunning) = 0;

Q_SIGNALS:
    void ActiveSceneIndexChanged(qint32 ActiveSceneIndex);
    void ScenesChanged(QList<SceneInfo> Scenes);
    void DevicesChanged(QList<DeviceInfo> Devices);
    void BridgesChanged(QList<BridgeInfo> Bridges);
    void RazerChanged(RazerInfo Razer);
    void IsRunningChanged(bool IsRunning);

public Q_SLOTS:
    virtual void pushActiveSceneIndex(qint32 ActiveSceneIndex)
    {
        setActiveSceneIndex(ActiveSceneIndex);
    }
    virtual void pushScenes(QList<SceneInfo> Scenes)
    {
        setScenes(Scenes);
    }
    virtual void pushDevices(QList<DeviceInfo> Devices)
    {
        setDevices(Devices);
    }
    virtual void pushBridges(QList<BridgeInfo> Bridges)
    {
        setBridges(Bridges);
    }
    virtual void pushRazer(RazerInfo Razer)
    {
        setRazer(Razer);
    }
    virtual void pushIsRunning(bool IsRunning)
    {
        setIsRunning(IsRunning);
    }

private:
    friend class QT_PREPEND_NAMESPACE(QRemoteObjectNode);
};

#if (QT_VERSION < QT_VERSION_CHECK(5, 5, 0))
#endif


class FrontendSimpleSource : public FrontendSource
{
    Q_OBJECT

public:
    explicit FrontendSimpleSource(QObject *parent = nullptr) : FrontendSource(parent)
    , m_ActiveSceneIndex()
    , m_Scenes()
    , m_Devices()
    , m_Bridges()
    , m_Razer()
    , m_IsRunning()
    {
    }

public:
    virtual ~FrontendSimpleSource() {}

    qint32 ActiveSceneIndex() const override { return m_ActiveSceneIndex; }
    QList<SceneInfo> Scenes() const override { return m_Scenes; }
    QList<DeviceInfo> Devices() const override { return m_Devices; }
    QList<BridgeInfo> Bridges() const override { return m_Bridges; }
    RazerInfo Razer() const override { return m_Razer; }
    bool IsRunning() const override { return m_IsRunning; }
    virtual void setActiveSceneIndex(qint32 ActiveSceneIndex) override
    {
        if (ActiveSceneIndex != m_ActiveSceneIndex) {
            m_ActiveSceneIndex = ActiveSceneIndex;
            Q_EMIT ActiveSceneIndexChanged(m_ActiveSceneIndex);
        }
    }
    virtual void setScenes(QList<SceneInfo> Scenes) override
    {
        if (Scenes != m_Scenes) {
            m_Scenes = Scenes;
            Q_EMIT ScenesChanged(m_Scenes);
        }
    }
    virtual void setDevices(QList<DeviceInfo> Devices) override
    {
        if (Devices != m_Devices) {
            m_Devices = Devices;
            Q_EMIT DevicesChanged(m_Devices);
        }
    }
    virtual void setBridges(QList<BridgeInfo> Bridges) override
    {
        if (Bridges != m_Bridges) {
            m_Bridges = Bridges;
            Q_EMIT BridgesChanged(m_Bridges);
        }
    }
    virtual void setRazer(RazerInfo Razer) override
    {
        if (Razer != m_Razer) {
            m_Razer = Razer;
            Q_EMIT RazerChanged(m_Razer);
        }
    }
    virtual void setIsRunning(bool IsRunning) override
    {
        if (IsRunning != m_IsRunning) {
            m_IsRunning = IsRunning;
            Q_EMIT IsRunningChanged(m_IsRunning);
        }
    }

private:
    qint32 m_ActiveSceneIndex;
    QList<SceneInfo> m_Scenes;
    QList<DeviceInfo> m_Devices;
    QList<BridgeInfo> m_Bridges;
    RazerInfo m_Razer;
    bool m_IsRunning;
};


template <class ObjectType>
struct FrontendSourceAPI : public SourceApiMap
{
    FrontendSourceAPI(ObjectType *object, const QString &name = QStringLiteral("Frontend"))
        : SourceApiMap(), m_name(name)
    {
        Q_UNUSED(object);
        m_enums[0] = 0;
        m_properties[0] = 6;
        m_properties[1] = QtPrivate::qtro_property_index<ObjectType>(&ObjectType::ActiveSceneIndex, static_cast<qint32 (QObject::*)()>(0),"ActiveSceneIndex");
        QtPrivate::qtro_method_test<ObjectType>(&ObjectType::ActiveSceneIndexChanged, static_cast<void (QObject::*)()>(0));
        m_properties[2] = QtPrivate::qtro_property_index<ObjectType>(&ObjectType::Scenes, static_cast<QList<SceneInfo> (QObject::*)()>(0),"Scenes");
        QtPrivate::qtro_method_test<ObjectType>(&ObjectType::ScenesChanged, static_cast<void (QObject::*)()>(0));
        m_properties[3] = QtPrivate::qtro_property_index<ObjectType>(&ObjectType::Devices, static_cast<QList<DeviceInfo> (QObject::*)()>(0),"Devices");
        QtPrivate::qtro_method_test<ObjectType>(&ObjectType::DevicesChanged, static_cast<void (QObject::*)()>(0));
        m_properties[4] = QtPrivate::qtro_property_index<ObjectType>(&ObjectType::Bridges, static_cast<QList<BridgeInfo> (QObject::*)()>(0),"Bridges");
        QtPrivate::qtro_method_test<ObjectType>(&ObjectType::BridgesChanged, static_cast<void (QObject::*)()>(0));
        m_properties[5] = QtPrivate::qtro_property_index<ObjectType>(&ObjectType::Razer, static_cast<RazerInfo (QObject::*)()>(0),"Razer");
        QtPrivate::qtro_method_test<ObjectType>(&ObjectType::RazerChanged, static_cast<void (QObject::*)()>(0));
        m_properties[6] = QtPrivate::qtro_property_index<ObjectType>(&ObjectType::IsRunning, static_cast<bool (QObject::*)()>(0),"IsRunning");
        QtPrivate::qtro_method_test<ObjectType>(&ObjectType::IsRunningChanged, static_cast<void (QObject::*)()>(0));
        m_signals[0] = 6;
        m_signals[1] = QtPrivate::qtro_signal_index<ObjectType>(&ObjectType::ActiveSceneIndexChanged, static_cast<void (QObject::*)(qint32)>(0),m_signalArgCount+0,&m_signalArgTypes[0]);
        m_signals[2] = QtPrivate::qtro_signal_index<ObjectType>(&ObjectType::ScenesChanged, static_cast<void (QObject::*)(QList<SceneInfo>)>(0),m_signalArgCount+1,&m_signalArgTypes[1]);
        m_signals[3] = QtPrivate::qtro_signal_index<ObjectType>(&ObjectType::DevicesChanged, static_cast<void (QObject::*)(QList<DeviceInfo>)>(0),m_signalArgCount+2,&m_signalArgTypes[2]);
        m_signals[4] = QtPrivate::qtro_signal_index<ObjectType>(&ObjectType::BridgesChanged, static_cast<void (QObject::*)(QList<BridgeInfo>)>(0),m_signalArgCount+3,&m_signalArgTypes[3]);
        m_signals[5] = QtPrivate::qtro_signal_index<ObjectType>(&ObjectType::RazerChanged, static_cast<void (QObject::*)(RazerInfo)>(0),m_signalArgCount+4,&m_signalArgTypes[4]);
        m_signals[6] = QtPrivate::qtro_signal_index<ObjectType>(&ObjectType::IsRunningChanged, static_cast<void (QObject::*)(bool)>(0),m_signalArgCount+5,&m_signalArgTypes[5]);
        m_methods[0] = 6;
        m_methods[1] = QtPrivate::qtro_method_index<ObjectType>(&ObjectType::pushActiveSceneIndex, static_cast<void (QObject::*)(qint32)>(0),"pushActiveSceneIndex(qint32)",m_methodArgCount+0,&m_methodArgTypes[0]);
        m_methods[2] = QtPrivate::qtro_method_index<ObjectType>(&ObjectType::pushScenes, static_cast<void (QObject::*)(QList<SceneInfo>)>(0),"pushScenes(QList<SceneInfo>)",m_methodArgCount+1,&m_methodArgTypes[1]);
        m_methods[3] = QtPrivate::qtro_method_index<ObjectType>(&ObjectType::pushDevices, static_cast<void (QObject::*)(QList<DeviceInfo>)>(0),"pushDevices(QList<DeviceInfo>)",m_methodArgCount+2,&m_methodArgTypes[2]);
        m_methods[4] = QtPrivate::qtro_method_index<ObjectType>(&ObjectType::pushBridges, static_cast<void (QObject::*)(QList<BridgeInfo>)>(0),"pushBridges(QList<BridgeInfo>)",m_methodArgCount+3,&m_methodArgTypes[3]);
        m_methods[5] = QtPrivate::qtro_method_index<ObjectType>(&ObjectType::pushRazer, static_cast<void (QObject::*)(RazerInfo)>(0),"pushRazer(RazerInfo)",m_methodArgCount+4,&m_methodArgTypes[4]);
        m_methods[6] = QtPrivate::qtro_method_index<ObjectType>(&ObjectType::pushIsRunning, static_cast<void (QObject::*)(bool)>(0),"pushIsRunning(bool)",m_methodArgCount+5,&m_methodArgTypes[5]);
    }

    QString name() const override { return m_name; }
    QString typeName() const override { return QStringLiteral("Frontend"); }
    int enumCount() const override { return m_enums[0]; }
    int propertyCount() const override { return m_properties[0]; }
    int signalCount() const override { return m_signals[0]; }
    int methodCount() const override { return m_methods[0]; }
    int sourceEnumIndex(int index) const override
    {
        if (index < 0 || index >= m_enums[0])
            return -1;
        return m_enums[index+1];
    }
    int sourcePropertyIndex(int index) const override
    {
        if (index < 0 || index >= m_properties[0])
            return -1;
        return m_properties[index+1];
    }
    int sourceSignalIndex(int index) const override
    {
        if (index < 0 || index >= m_signals[0])
            return -1;
        return m_signals[index+1];
    }
    int sourceMethodIndex(int index) const override
    {
        if (index < 0 || index >= m_methods[0])
            return -1;
        return m_methods[index+1];
    }
    int signalParameterCount(int index) const override
    {
        if (index < 0 || index >= m_signals[0])
            return -1;
        return m_signalArgCount[index];
    }
    int signalParameterType(int sigIndex, int paramIndex) const override
    {
        if (sigIndex < 0 || sigIndex >= m_signals[0] || paramIndex < 0 || paramIndex >= m_signalArgCount[sigIndex])
            return -1;
        return m_signalArgTypes[sigIndex][paramIndex];
    }
    int methodParameterCount(int index) const override
    {
        if (index < 0 || index >= m_methods[0])
            return -1;
        return m_methodArgCount[index];
    }
    int methodParameterType(int methodIndex, int paramIndex) const override
    {
        if (methodIndex < 0 || methodIndex >= m_methods[0] || paramIndex < 0 || paramIndex >= m_methodArgCount[methodIndex])
            return -1;
        return m_methodArgTypes[methodIndex][paramIndex];
    }
    int propertyIndexFromSignal(int index) const override
    {
        switch (index) {
        case 0: return m_properties[1];
        case 1: return m_properties[2];
        case 2: return m_properties[3];
        case 3: return m_properties[4];
        case 4: return m_properties[5];
        case 5: return m_properties[6];
        }
        return -1;
    }
    int propertyRawIndexFromSignal(int index) const override
    {
        switch (index) {
        case 0: return 0;
        case 1: return 1;
        case 2: return 2;
        case 3: return 3;
        case 4: return 4;
        case 5: return 5;
        }
        return -1;
    }
    const QByteArray signalSignature(int index) const override
    {
        switch (index) {
        case 0: return QByteArrayLiteral("ActiveSceneIndexChanged(qint32)");
        case 1: return QByteArrayLiteral("ScenesChanged(QList<SceneInfo>)");
        case 2: return QByteArrayLiteral("DevicesChanged(QList<DeviceInfo>)");
        case 3: return QByteArrayLiteral("BridgesChanged(QList<BridgeInfo>)");
        case 4: return QByteArrayLiteral("RazerChanged(RazerInfo)");
        case 5: return QByteArrayLiteral("IsRunningChanged(bool)");
        }
        return QByteArrayLiteral("");
    }
    QList<QByteArray> signalParameterNames(int index) const override
    {
        if (index < 0 || index >= m_signals[0])
            return QList<QByteArray>();
        return ObjectType::staticMetaObject.method(m_signals[index + 1]).parameterNames();
    }
    const QByteArray methodSignature(int index) const override
    {
        switch (index) {
        case 0: return QByteArrayLiteral("pushActiveSceneIndex(qint32)");
        case 1: return QByteArrayLiteral("pushScenes(QList<SceneInfo>)");
        case 2: return QByteArrayLiteral("pushDevices(QList<DeviceInfo>)");
        case 3: return QByteArrayLiteral("pushBridges(QList<BridgeInfo>)");
        case 4: return QByteArrayLiteral("pushRazer(RazerInfo)");
        case 5: return QByteArrayLiteral("pushIsRunning(bool)");
        }
        return QByteArrayLiteral("");
    }
    QMetaMethod::MethodType methodType(int) const override
    {
        return QMetaMethod::Slot;
    }
    QList<QByteArray> methodParameterNames(int index) const override
    {
        if (index < 0 || index >= m_methods[0])
            return QList<QByteArray>();
        return ObjectType::staticMetaObject.method(m_methods[index + 1]).parameterNames();
    }
    const QByteArray typeName(int index) const override
    {
        switch (index) {
        case 0: return QByteArrayLiteral("void");
        case 1: return QByteArrayLiteral("void");
        case 2: return QByteArrayLiteral("void");
        case 3: return QByteArrayLiteral("void");
        case 4: return QByteArrayLiteral("void");
        case 5: return QByteArrayLiteral("void");
        }
        return QByteArrayLiteral("");
    }
    QByteArray objectSignature() const override { return QByteArray{"8e55f9a1328c0af1d084e5a8d6f54c5daec1cb63"}; }

    int m_enums[1];
    int m_properties[7];
    int m_signals[7];
    int m_methods[7];
    const QString m_name;
    int m_signalArgCount[6];
    const int* m_signalArgTypes[6];
    int m_methodArgCount[6];
    const int* m_methodArgTypes[6];
};

QT_BEGIN_NAMESPACE
QT_END_NAMESPACE


#endif // REP_FRONTEND_H
