/****************************************************************************
** Meta object code from reading C++ file 'device.hpp'
**
** Created by: The Qt Meta Object Compiler version 69 (Qt 6.11.2)
**
** WARNING! All changes made in this file will be lost!
*****************************************************************************/

#include "../../../../../src/network/device.hpp"
#include <QtCore/qmetatype.h>
#include <QtCore/QProperty>

#include <QtCore/qtmochelpers.h>

#include <memory>


#include <QtCore/qxptype_traits.h>
#if !defined(Q_MOC_OUTPUT_REVISION)
#error "The header file 'device.hpp' doesn't include <QObject>."
#elif Q_MOC_OUTPUT_REVISION != 69
#error "This file was generated using the moc from 6.11.2. It"
#error "cannot be used with the include files from this version of Qt."
#error "(The moc has changed too much.)"
#endif

#ifndef Q_CONSTINIT
#define Q_CONSTINIT
#endif

QT_WARNING_PUSH
QT_WARNING_DISABLE_DEPRECATED
QT_WARNING_DISABLE_GCC("-Wuseless-cast")
namespace {
struct qt_meta_tag_ZN2qs7network13NetworkDeviceE_t {};
} // unnamed namespace

template <> constexpr inline auto qs::network::NetworkDevice::qt_create_metaobjectdata<qt_meta_tag_ZN2qs7network13NetworkDeviceE_t>()
{
    namespace QMC = QtMocConstants;
    QtMocHelpers::StringRefStorage qt_stringData {
        "qs::network::NetworkDevice",
        "QML.Element",
        "auto",
        "QML.Creatable",
        "false",
        "QML.UncreatableReason",
        "Devices can only be acquired through Network",
        "requestDisconnect",
        "",
        "requestSetAutoconnect",
        "autoconnect",
        "requestSetNmManaged",
        "managed",
        "nameChanged",
        "addressChanged",
        "connectedChanged",
        "stateChanged",
        "nmManagedChanged",
        "autoconnectChanged",
        "disconnect",
        "type",
        "DeviceType::Enum",
        "name",
        "networks",
        "UntypedObjectModel*",
        "address",
        "connected",
        "state",
        "qs::network::ConnectionState::Enum",
        "nmManaged"
    };

    QtMocHelpers::UintData qt_methods {
        // Signal 'requestDisconnect'
        QtMocHelpers::SignalData<void()>(7, 8, QMC::AccessPublic, QMetaType::Void),
        // Signal 'requestSetAutoconnect'
        QtMocHelpers::SignalData<void(bool)>(9, 8, QMC::AccessPublic, QMetaType::Void, {{
            { QMetaType::Bool, 10 },
        }}),
        // Signal 'requestSetNmManaged'
        QtMocHelpers::SignalData<void(bool)>(11, 8, QMC::AccessPublic, QMetaType::Void, {{
            { QMetaType::Bool, 12 },
        }}),
        // Signal 'nameChanged'
        QtMocHelpers::SignalData<void()>(13, 8, QMC::AccessPublic, QMetaType::Void),
        // Signal 'addressChanged'
        QtMocHelpers::SignalData<void()>(14, 8, QMC::AccessPublic, QMetaType::Void),
        // Signal 'connectedChanged'
        QtMocHelpers::SignalData<void()>(15, 8, QMC::AccessPublic, QMetaType::Void),
        // Signal 'stateChanged'
        QtMocHelpers::SignalData<void()>(16, 8, QMC::AccessPublic, QMetaType::Void),
        // Signal 'nmManagedChanged'
        QtMocHelpers::SignalData<void()>(17, 8, QMC::AccessPublic, QMetaType::Void),
        // Signal 'autoconnectChanged'
        QtMocHelpers::SignalData<void()>(18, 8, QMC::AccessPublic, QMetaType::Void),
        // Method 'disconnect'
        QtMocHelpers::MethodData<void()>(19, 8, QMC::AccessPublic, QMetaType::Void),
    };
    QtMocHelpers::UintData qt_properties {
        // property 'type'
        QtMocHelpers::PropertyData<DeviceType::Enum>(20, 0x80000000 | 21, QMC::DefaultPropertyFlags | QMC::EnumOrFlag | QMC::Constant),
        // property 'name'
        QtMocHelpers::PropertyData<QString>(22, QMetaType::QString, QMC::DefaultPropertyFlags | QMC::Bindable, 3),
        // property 'networks'
        QtMocHelpers::PropertyData<UntypedObjectModel*>(23, 0x80000000 | 24, QMC::DefaultPropertyFlags | QMC::EnumOrFlag | QMC::Constant),
        // property 'address'
        QtMocHelpers::PropertyData<QString>(25, QMetaType::QString, QMC::DefaultPropertyFlags | QMC::Bindable, 4),
        // property 'connected'
        QtMocHelpers::PropertyData<bool>(26, QMetaType::Bool, QMC::DefaultPropertyFlags | QMC::Bindable, 5),
        // property 'state'
        QtMocHelpers::PropertyData<qs::network::ConnectionState::Enum>(27, 0x80000000 | 28, QMC::DefaultPropertyFlags | QMC::EnumOrFlag | QMC::Bindable, 6),
        // property 'nmManaged'
        QtMocHelpers::PropertyData<bool>(29, QMetaType::Bool, QMC::DefaultPropertyFlags | QMC::Writable | QMC::StdCppSet, 7),
        // property 'autoconnect'
        QtMocHelpers::PropertyData<bool>(10, QMetaType::Bool, QMC::DefaultPropertyFlags | QMC::Writable | QMC::StdCppSet, 8),
    };
    QtMocHelpers::UintData qt_enums {
    };
    QtMocHelpers::UintData qt_constructors {};
    QtMocHelpers::ClassInfos qt_classinfo({
            {    1,    2 },
            {    3,    4 },
            {    5,    6 },
    });
    return QtMocHelpers::metaObjectData<NetworkDevice, void>(QMC::MetaObjectFlag{}, qt_stringData,
            qt_methods, qt_properties, qt_enums, qt_constructors, qt_classinfo);
}
Q_CONSTINIT static const QMetaObject::SuperData qt_meta_extradata_ZN2qs7network13NetworkDeviceE[] = {
    QMetaObject::SuperData::link<qs::network::DeviceType::staticMetaObject>(),
    QMetaObject::SuperData::link<qs::network::ConnectionState::staticMetaObject>(),
    nullptr
};

Q_CONSTINIT const QMetaObject qs::network::NetworkDevice::staticMetaObject = { {
    QMetaObject::SuperData::link<QObject::staticMetaObject>(),
    qt_staticMetaObjectStaticContent<qt_meta_tag_ZN2qs7network13NetworkDeviceE_t>.stringdata,
    qt_staticMetaObjectStaticContent<qt_meta_tag_ZN2qs7network13NetworkDeviceE_t>.data,
    qt_static_metacall,
    qt_meta_extradata_ZN2qs7network13NetworkDeviceE,
    qt_staticMetaObjectRelocatingContent<qt_meta_tag_ZN2qs7network13NetworkDeviceE_t>.metaTypes,
    nullptr
} };

void qs::network::NetworkDevice::qt_static_metacall(QObject *_o, QMetaObject::Call _c, int _id, void **_a)
{
    auto *_t = static_cast<NetworkDevice *>(_o);
    if (_c == QMetaObject::InvokeMetaMethod) {
        switch (_id) {
        case 0: _t->requestDisconnect(); break;
        case 1: _t->requestSetAutoconnect((*reinterpret_cast<std::add_pointer_t<bool>>(_a[1]))); break;
        case 2: _t->requestSetNmManaged((*reinterpret_cast<std::add_pointer_t<bool>>(_a[1]))); break;
        case 3: _t->nameChanged(); break;
        case 4: _t->addressChanged(); break;
        case 5: _t->connectedChanged(); break;
        case 6: _t->stateChanged(); break;
        case 7: _t->nmManagedChanged(); break;
        case 8: _t->autoconnectChanged(); break;
        case 9: _t->disconnect(); break;
        default: ;
        }
    }
    if (_c == QMetaObject::IndexOfMethod) {
        if (QtMocHelpers::indexOfMethod<void (NetworkDevice::*)()>(_a, &NetworkDevice::requestDisconnect, 0))
            return;
        if (QtMocHelpers::indexOfMethod<void (NetworkDevice::*)(bool )>(_a, &NetworkDevice::requestSetAutoconnect, 1))
            return;
        if (QtMocHelpers::indexOfMethod<void (NetworkDevice::*)(bool )>(_a, &NetworkDevice::requestSetNmManaged, 2))
            return;
        if (QtMocHelpers::indexOfMethod<void (NetworkDevice::*)()>(_a, &NetworkDevice::nameChanged, 3))
            return;
        if (QtMocHelpers::indexOfMethod<void (NetworkDevice::*)()>(_a, &NetworkDevice::addressChanged, 4))
            return;
        if (QtMocHelpers::indexOfMethod<void (NetworkDevice::*)()>(_a, &NetworkDevice::connectedChanged, 5))
            return;
        if (QtMocHelpers::indexOfMethod<void (NetworkDevice::*)()>(_a, &NetworkDevice::stateChanged, 6))
            return;
        if (QtMocHelpers::indexOfMethod<void (NetworkDevice::*)()>(_a, &NetworkDevice::nmManagedChanged, 7))
            return;
        if (QtMocHelpers::indexOfMethod<void (NetworkDevice::*)()>(_a, &NetworkDevice::autoconnectChanged, 8))
            return;
    }
    if (_c == QMetaObject::RegisterPropertyMetaType) {
        switch (_id) {
        default: *reinterpret_cast<int*>(_a[0]) = -1; break;
        case 2:
            *reinterpret_cast<int*>(_a[0]) = qRegisterMetaType< UntypedObjectModel* >(); break;
        }
    }
    if (_c == QMetaObject::ReadProperty) {
        void *_v = _a[0];
        switch (_id) {
        case 0: *reinterpret_cast<DeviceType::Enum*>(_v) = _t->type(); break;
        case 1: *reinterpret_cast<QString*>(_v) = _t->name(); break;
        case 2: *reinterpret_cast<UntypedObjectModel**>(_v) = _t->networks(); break;
        case 3: *reinterpret_cast<QString*>(_v) = _t->bindableAddress().value(); break;
        case 4: *reinterpret_cast<bool*>(_v) = _t->bindableConnected().value(); break;
        case 5: *reinterpret_cast<qs::network::ConnectionState::Enum*>(_v) = _t->bindableState().value(); break;
        case 6: *reinterpret_cast<bool*>(_v) = _t->nmManaged(); break;
        case 7: *reinterpret_cast<bool*>(_v) = _t->autoconnect(); break;
        default: break;
        }
    }
    if (_c == QMetaObject::WriteProperty) {
        void *_v = _a[0];
        switch (_id) {
        case 6: _t->setNmManaged(*reinterpret_cast<bool*>(_v)); break;
        case 7: _t->setAutoconnect(*reinterpret_cast<bool*>(_v)); break;
        default: break;
        }
    }
    if (_c == QMetaObject::BindableProperty) {
        switch (_id) {
        case 1: *static_cast<QUntypedBindable *>(_a[0]) = _t->bindableName(); break;
        case 3: *static_cast<QUntypedBindable *>(_a[0]) = _t->bindableAddress(); break;
        case 4: *static_cast<QUntypedBindable *>(_a[0]) = _t->bindableConnected(); break;
        case 5: *static_cast<QUntypedBindable *>(_a[0]) = _t->bindableState(); break;
        default: break;
        }
    }
}

const QMetaObject *qs::network::NetworkDevice::metaObject() const
{
    return QObject::d_ptr->metaObject ? QObject::d_ptr->dynamicMetaObject() : &staticMetaObject;
}

void *qs::network::NetworkDevice::qt_metacast(const char *_clname)
{
    if (!_clname) return nullptr;
    if (!strcmp(_clname, qt_staticMetaObjectStaticContent<qt_meta_tag_ZN2qs7network13NetworkDeviceE_t>.strings))
        return static_cast<void*>(this);
    return QObject::qt_metacast(_clname);
}

int qs::network::NetworkDevice::qt_metacall(QMetaObject::Call _c, int _id, void **_a)
{
    _id = QObject::qt_metacall(_c, _id, _a);
    if (_id < 0)
        return _id;
    if (_c == QMetaObject::InvokeMetaMethod) {
        if (_id < 10)
            qt_static_metacall(this, _c, _id, _a);
        _id -= 10;
    }
    if (_c == QMetaObject::RegisterMethodArgumentMetaType) {
        if (_id < 10)
            *reinterpret_cast<QMetaType *>(_a[0]) = QMetaType();
        _id -= 10;
    }
    if (_c == QMetaObject::ReadProperty || _c == QMetaObject::WriteProperty
            || _c == QMetaObject::ResetProperty || _c == QMetaObject::BindableProperty
            || _c == QMetaObject::RegisterPropertyMetaType) {
        qt_static_metacall(this, _c, _id, _a);
        _id -= 8;
    }
    return _id;
}

// SIGNAL 0
void qs::network::NetworkDevice::requestDisconnect()
{
    QMetaObject::activate(this, &staticMetaObject, 0, nullptr);
}

// SIGNAL 1
void qs::network::NetworkDevice::requestSetAutoconnect(bool _t1)
{
    QMetaObject::activate<void>(this, &staticMetaObject, 1, nullptr, _t1);
}

// SIGNAL 2
void qs::network::NetworkDevice::requestSetNmManaged(bool _t1)
{
    QMetaObject::activate<void>(this, &staticMetaObject, 2, nullptr, _t1);
}

// SIGNAL 3
void qs::network::NetworkDevice::nameChanged()
{
    QMetaObject::activate(this, &staticMetaObject, 3, nullptr);
}

// SIGNAL 4
void qs::network::NetworkDevice::addressChanged()
{
    QMetaObject::activate(this, &staticMetaObject, 4, nullptr);
}

// SIGNAL 5
void qs::network::NetworkDevice::connectedChanged()
{
    QMetaObject::activate(this, &staticMetaObject, 5, nullptr);
}

// SIGNAL 6
void qs::network::NetworkDevice::stateChanged()
{
    QMetaObject::activate(this, &staticMetaObject, 6, nullptr);
}

// SIGNAL 7
void qs::network::NetworkDevice::nmManagedChanged()
{
    QMetaObject::activate(this, &staticMetaObject, 7, nullptr);
}

// SIGNAL 8
void qs::network::NetworkDevice::autoconnectChanged()
{
    QMetaObject::activate(this, &staticMetaObject, 8, nullptr);
}
QT_WARNING_POP
