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

#include "../../power/dbus/upowerdeviceinterface.h"
#include <QtCore/qmetatype.h>

#include <QtCore/qtmochelpers.h>

#include <memory>


#include <QtCore/qxptype_traits.h>
#if !defined(Q_MOC_OUTPUT_REVISION)
#error "The header file 'upowerdeviceinterface.h' doesn't include <QObject>."
#elif Q_MOC_OUTPUT_REVISION != 69
#error "This file was generated using the moc from 6.10.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_ZN3Dtk5Power21UPowerDeviceInterfaceE_t {};
} // unnamed namespace

template <> constexpr inline auto Dtk::Power::UPowerDeviceInterface::qt_create_metaobjectdata<qt_meta_tag_ZN3Dtk5Power21UPowerDeviceInterfaceE_t>()
{
    namespace QMC = QtMocConstants;
    QtMocHelpers::StringRefStorage qt_stringData {
        "Dtk::Power::UPowerDeviceInterface",
        "UpdateTimeChanged",
        "",
        "value",
        "PercentageChanged",
        "TimeToEmptyChanged",
        "TimeToFullChanged",
        "EnergyRateChanged",
        "EnergyChanged",
        "IconNameChanged",
        "getHistory",
        "QDBusPendingReply<QList<Dtk::Power::History_p>>",
        "type",
        "timespan",
        "resolution",
        "getStatistics",
        "QDBusPendingReply<QList<Dtk::Power::Statistic_p>>",
        "refresh",
        "QDBusPendingReply<>",
        "HasHistory",
        "HasStatistics",
        "IsPresent",
        "IsRechargeable",
        "Online",
        "PowerSupply",
        "Capacity",
        "Energy",
        "EnergyEmpty",
        "EnergyFull",
        "EnergyFullDesign",
        "EnergyRate",
        "Luminosity",
        "Percentage",
        "Temperature",
        "Voltage",
        "ChargeCycles",
        "TimeToEmpty",
        "TimeToFull",
        "IconName",
        "Model",
        "NativePath",
        "Serial",
        "Vendor",
        "BatteryLevel",
        "State",
        "Technology",
        "Type",
        "WarningLevel",
        "UpdateTime",
        "DeviceName"
    };

    QtMocHelpers::UintData qt_methods {
        // Signal 'UpdateTimeChanged'
        QtMocHelpers::SignalData<void(const quint64)>(1, 2, QMC::AccessPublic, QMetaType::Void, {{
            { QMetaType::ULongLong, 3 },
        }}),
        // Signal 'PercentageChanged'
        QtMocHelpers::SignalData<void(const double)>(4, 2, QMC::AccessPublic, QMetaType::Void, {{
            { QMetaType::Double, 3 },
        }}),
        // Signal 'TimeToEmptyChanged'
        QtMocHelpers::SignalData<void(const qint64)>(5, 2, QMC::AccessPublic, QMetaType::Void, {{
            { QMetaType::LongLong, 3 },
        }}),
        // Signal 'TimeToFullChanged'
        QtMocHelpers::SignalData<void(const qint64)>(6, 2, QMC::AccessPublic, QMetaType::Void, {{
            { QMetaType::LongLong, 3 },
        }}),
        // Signal 'EnergyRateChanged'
        QtMocHelpers::SignalData<void(const double)>(7, 2, QMC::AccessPublic, QMetaType::Void, {{
            { QMetaType::Double, 3 },
        }}),
        // Signal 'EnergyChanged'
        QtMocHelpers::SignalData<void(const double)>(8, 2, QMC::AccessPublic, QMetaType::Void, {{
            { QMetaType::Double, 3 },
        }}),
        // Signal 'IconNameChanged'
        QtMocHelpers::SignalData<void(const QString &)>(9, 2, QMC::AccessPublic, QMetaType::Void, {{
            { QMetaType::QString, 3 },
        }}),
        // Slot 'getHistory'
        QtMocHelpers::SlotData<QDBusPendingReply<QList<Dtk::Power::History_p>>(const QString &, const uint, const uint) const>(10, 2, QMC::AccessPublic, 0x80000000 | 11, {{
            { QMetaType::QString, 12 }, { QMetaType::UInt, 13 }, { QMetaType::UInt, 14 },
        }}),
        // Slot 'getStatistics'
        QtMocHelpers::SlotData<QDBusPendingReply<QList<Dtk::Power::Statistic_p>>(const QString &) const>(15, 2, QMC::AccessPublic, 0x80000000 | 16, {{
            { QMetaType::QString, 12 },
        }}),
        // Slot 'refresh'
        QtMocHelpers::SlotData<QDBusPendingReply<>()>(17, 2, QMC::AccessPublic, 0x80000000 | 18),
    };
    QtMocHelpers::UintData qt_properties {
        // property 'HasHistory'
        QtMocHelpers::PropertyData<bool>(19, QMetaType::Bool, QMC::DefaultPropertyFlags),
        // property 'HasStatistics'
        QtMocHelpers::PropertyData<bool>(20, QMetaType::Bool, QMC::DefaultPropertyFlags),
        // property 'IsPresent'
        QtMocHelpers::PropertyData<bool>(21, QMetaType::Bool, QMC::DefaultPropertyFlags),
        // property 'IsRechargeable'
        QtMocHelpers::PropertyData<bool>(22, QMetaType::Bool, QMC::DefaultPropertyFlags),
        // property 'Online'
        QtMocHelpers::PropertyData<bool>(23, QMetaType::Bool, QMC::DefaultPropertyFlags),
        // property 'PowerSupply'
        QtMocHelpers::PropertyData<bool>(24, QMetaType::Bool, QMC::DefaultPropertyFlags),
        // property 'Capacity'
        QtMocHelpers::PropertyData<double>(25, QMetaType::Double, QMC::DefaultPropertyFlags),
        // property 'Energy'
        QtMocHelpers::PropertyData<double>(26, QMetaType::Double, QMC::DefaultPropertyFlags, 5),
        // property 'EnergyEmpty'
        QtMocHelpers::PropertyData<double>(27, QMetaType::Double, QMC::DefaultPropertyFlags),
        // property 'EnergyFull'
        QtMocHelpers::PropertyData<double>(28, QMetaType::Double, QMC::DefaultPropertyFlags),
        // property 'EnergyFullDesign'
        QtMocHelpers::PropertyData<double>(29, QMetaType::Double, QMC::DefaultPropertyFlags),
        // property 'EnergyRate'
        QtMocHelpers::PropertyData<double>(30, QMetaType::Double, QMC::DefaultPropertyFlags, 4),
        // property 'Luminosity'
        QtMocHelpers::PropertyData<double>(31, QMetaType::Double, QMC::DefaultPropertyFlags),
        // property 'Percentage'
        QtMocHelpers::PropertyData<double>(32, QMetaType::Double, QMC::DefaultPropertyFlags, 1),
        // property 'Temperature'
        QtMocHelpers::PropertyData<double>(33, QMetaType::Double, QMC::DefaultPropertyFlags),
        // property 'Voltage'
        QtMocHelpers::PropertyData<double>(34, QMetaType::Double, QMC::DefaultPropertyFlags),
        // property 'ChargeCycles'
        QtMocHelpers::PropertyData<quint32>(35, QMetaType::UInt, QMC::DefaultPropertyFlags),
        // property 'TimeToEmpty'
        QtMocHelpers::PropertyData<qint64>(36, QMetaType::LongLong, QMC::DefaultPropertyFlags, 2),
        // property 'TimeToFull'
        QtMocHelpers::PropertyData<qint64>(37, QMetaType::LongLong, QMC::DefaultPropertyFlags, 3),
        // property 'IconName'
        QtMocHelpers::PropertyData<QString>(38, QMetaType::QString, QMC::DefaultPropertyFlags, 6),
        // property 'Model'
        QtMocHelpers::PropertyData<QString>(39, QMetaType::QString, QMC::DefaultPropertyFlags),
        // property 'NativePath'
        QtMocHelpers::PropertyData<QString>(40, QMetaType::QString, QMC::DefaultPropertyFlags),
        // property 'Serial'
        QtMocHelpers::PropertyData<QString>(41, QMetaType::QString, QMC::DefaultPropertyFlags),
        // property 'Vendor'
        QtMocHelpers::PropertyData<QString>(42, QMetaType::QString, QMC::DefaultPropertyFlags),
        // property 'BatteryLevel'
        QtMocHelpers::PropertyData<quint32>(43, QMetaType::UInt, QMC::DefaultPropertyFlags),
        // property 'State'
        QtMocHelpers::PropertyData<quint32>(44, QMetaType::UInt, QMC::DefaultPropertyFlags),
        // property 'Technology'
        QtMocHelpers::PropertyData<quint32>(45, QMetaType::UInt, QMC::DefaultPropertyFlags),
        // property 'Type'
        QtMocHelpers::PropertyData<quint32>(46, QMetaType::UInt, QMC::DefaultPropertyFlags),
        // property 'WarningLevel'
        QtMocHelpers::PropertyData<quint32>(47, QMetaType::UInt, QMC::DefaultPropertyFlags),
        // property 'UpdateTime'
        QtMocHelpers::PropertyData<quint64>(48, QMetaType::ULongLong, QMC::DefaultPropertyFlags, 0),
        // property 'DeviceName'
        QtMocHelpers::PropertyData<QString>(49, QMetaType::QString, QMC::DefaultPropertyFlags),
    };
    QtMocHelpers::UintData qt_enums {
    };
    return QtMocHelpers::metaObjectData<UPowerDeviceInterface, qt_meta_tag_ZN3Dtk5Power21UPowerDeviceInterfaceE_t>(QMC::MetaObjectFlag{}, qt_stringData,
            qt_methods, qt_properties, qt_enums);
}
Q_CONSTINIT const QMetaObject Dtk::Power::UPowerDeviceInterface::staticMetaObject = { {
    QMetaObject::SuperData::link<QObject::staticMetaObject>(),
    qt_staticMetaObjectStaticContent<qt_meta_tag_ZN3Dtk5Power21UPowerDeviceInterfaceE_t>.stringdata,
    qt_staticMetaObjectStaticContent<qt_meta_tag_ZN3Dtk5Power21UPowerDeviceInterfaceE_t>.data,
    qt_static_metacall,
    nullptr,
    qt_staticMetaObjectRelocatingContent<qt_meta_tag_ZN3Dtk5Power21UPowerDeviceInterfaceE_t>.metaTypes,
    nullptr
} };

void Dtk::Power::UPowerDeviceInterface::qt_static_metacall(QObject *_o, QMetaObject::Call _c, int _id, void **_a)
{
    auto *_t = static_cast<UPowerDeviceInterface *>(_o);
    if (_c == QMetaObject::InvokeMetaMethod) {
        switch (_id) {
        case 0: _t->UpdateTimeChanged((*reinterpret_cast<std::add_pointer_t<quint64>>(_a[1]))); break;
        case 1: _t->PercentageChanged((*reinterpret_cast<std::add_pointer_t<double>>(_a[1]))); break;
        case 2: _t->TimeToEmptyChanged((*reinterpret_cast<std::add_pointer_t<qint64>>(_a[1]))); break;
        case 3: _t->TimeToFullChanged((*reinterpret_cast<std::add_pointer_t<qint64>>(_a[1]))); break;
        case 4: _t->EnergyRateChanged((*reinterpret_cast<std::add_pointer_t<double>>(_a[1]))); break;
        case 5: _t->EnergyChanged((*reinterpret_cast<std::add_pointer_t<double>>(_a[1]))); break;
        case 6: _t->IconNameChanged((*reinterpret_cast<std::add_pointer_t<QString>>(_a[1]))); break;
        case 7: { QDBusPendingReply<QList<Dtk::Power::History_p>> _r = _t->getHistory((*reinterpret_cast<std::add_pointer_t<QString>>(_a[1])),(*reinterpret_cast<std::add_pointer_t<uint>>(_a[2])),(*reinterpret_cast<std::add_pointer_t<uint>>(_a[3])));
            if (_a[0]) *reinterpret_cast<QDBusPendingReply<QList<Dtk::Power::History_p>>*>(_a[0]) = std::move(_r); }  break;
        case 8: { QDBusPendingReply<QList<Dtk::Power::Statistic_p>> _r = _t->getStatistics((*reinterpret_cast<std::add_pointer_t<QString>>(_a[1])));
            if (_a[0]) *reinterpret_cast<QDBusPendingReply<QList<Dtk::Power::Statistic_p>>*>(_a[0]) = std::move(_r); }  break;
        case 9: { QDBusPendingReply<> _r = _t->refresh();
            if (_a[0]) *reinterpret_cast<QDBusPendingReply<>*>(_a[0]) = std::move(_r); }  break;
        default: ;
        }
    }
    if (_c == QMetaObject::IndexOfMethod) {
        if (QtMocHelpers::indexOfMethod<void (UPowerDeviceInterface::*)(const quint64 )>(_a, &UPowerDeviceInterface::UpdateTimeChanged, 0))
            return;
        if (QtMocHelpers::indexOfMethod<void (UPowerDeviceInterface::*)(const double )>(_a, &UPowerDeviceInterface::PercentageChanged, 1))
            return;
        if (QtMocHelpers::indexOfMethod<void (UPowerDeviceInterface::*)(const qint64 )>(_a, &UPowerDeviceInterface::TimeToEmptyChanged, 2))
            return;
        if (QtMocHelpers::indexOfMethod<void (UPowerDeviceInterface::*)(const qint64 )>(_a, &UPowerDeviceInterface::TimeToFullChanged, 3))
            return;
        if (QtMocHelpers::indexOfMethod<void (UPowerDeviceInterface::*)(const double )>(_a, &UPowerDeviceInterface::EnergyRateChanged, 4))
            return;
        if (QtMocHelpers::indexOfMethod<void (UPowerDeviceInterface::*)(const double )>(_a, &UPowerDeviceInterface::EnergyChanged, 5))
            return;
        if (QtMocHelpers::indexOfMethod<void (UPowerDeviceInterface::*)(const QString & )>(_a, &UPowerDeviceInterface::IconNameChanged, 6))
            return;
    }
    if (_c == QMetaObject::ReadProperty) {
        void *_v = _a[0];
        switch (_id) {
        case 0: *reinterpret_cast<bool*>(_v) = _t->hasHistory(); break;
        case 1: *reinterpret_cast<bool*>(_v) = _t->hasStatistics(); break;
        case 2: *reinterpret_cast<bool*>(_v) = _t->isPresent(); break;
        case 3: *reinterpret_cast<bool*>(_v) = _t->isRechargeable(); break;
        case 4: *reinterpret_cast<bool*>(_v) = _t->online(); break;
        case 5: *reinterpret_cast<bool*>(_v) = _t->powerSupply(); break;
        case 6: *reinterpret_cast<double*>(_v) = _t->capacity(); break;
        case 7: *reinterpret_cast<double*>(_v) = _t->energy(); break;
        case 8: *reinterpret_cast<double*>(_v) = _t->energyEmpty(); break;
        case 9: *reinterpret_cast<double*>(_v) = _t->energyFull(); break;
        case 10: *reinterpret_cast<double*>(_v) = _t->energyFullDesign(); break;
        case 11: *reinterpret_cast<double*>(_v) = _t->energyRate(); break;
        case 12: *reinterpret_cast<double*>(_v) = _t->luminosity(); break;
        case 13: *reinterpret_cast<double*>(_v) = _t->percentage(); break;
        case 14: *reinterpret_cast<double*>(_v) = _t->temperature(); break;
        case 15: *reinterpret_cast<double*>(_v) = _t->voltage(); break;
        case 16: *reinterpret_cast<quint32*>(_v) = _t->chargeCycles(); break;
        case 17: *reinterpret_cast<qint64*>(_v) = _t->timeToEmpty(); break;
        case 18: *reinterpret_cast<qint64*>(_v) = _t->timeToFull(); break;
        case 19: *reinterpret_cast<QString*>(_v) = _t->iconName(); break;
        case 20: *reinterpret_cast<QString*>(_v) = _t->model(); break;
        case 21: *reinterpret_cast<QString*>(_v) = _t->nativePath(); break;
        case 22: *reinterpret_cast<QString*>(_v) = _t->serial(); break;
        case 23: *reinterpret_cast<QString*>(_v) = _t->vendor(); break;
        case 24: *reinterpret_cast<quint32*>(_v) = _t->batteryLevel(); break;
        case 25: *reinterpret_cast<quint32*>(_v) = _t->state(); break;
        case 26: *reinterpret_cast<quint32*>(_v) = _t->technology(); break;
        case 27: *reinterpret_cast<quint32*>(_v) = _t->type(); break;
        case 28: *reinterpret_cast<quint32*>(_v) = _t->warningLevel(); break;
        case 29: *reinterpret_cast<quint64*>(_v) = _t->updateTime(); break;
        case 30: *reinterpret_cast<QString*>(_v) = _t->deviceName(); break;
        default: break;
        }
    }
}

const QMetaObject *Dtk::Power::UPowerDeviceInterface::metaObject() const
{
    return QObject::d_ptr->metaObject ? QObject::d_ptr->dynamicMetaObject() : &staticMetaObject;
}

void *Dtk::Power::UPowerDeviceInterface::qt_metacast(const char *_clname)
{
    if (!_clname) return nullptr;
    if (!strcmp(_clname, qt_staticMetaObjectStaticContent<qt_meta_tag_ZN3Dtk5Power21UPowerDeviceInterfaceE_t>.strings))
        return static_cast<void*>(this);
    return QObject::qt_metacast(_clname);
}

int Dtk::Power::UPowerDeviceInterface::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 -= 31;
    }
    return _id;
}

// SIGNAL 0
void Dtk::Power::UPowerDeviceInterface::UpdateTimeChanged(const quint64 _t1)
{
    QMetaObject::activate<void>(this, &staticMetaObject, 0, nullptr, _t1);
}

// SIGNAL 1
void Dtk::Power::UPowerDeviceInterface::PercentageChanged(const double _t1)
{
    QMetaObject::activate<void>(this, &staticMetaObject, 1, nullptr, _t1);
}

// SIGNAL 2
void Dtk::Power::UPowerDeviceInterface::TimeToEmptyChanged(const qint64 _t1)
{
    QMetaObject::activate<void>(this, &staticMetaObject, 2, nullptr, _t1);
}

// SIGNAL 3
void Dtk::Power::UPowerDeviceInterface::TimeToFullChanged(const qint64 _t1)
{
    QMetaObject::activate<void>(this, &staticMetaObject, 3, nullptr, _t1);
}

// SIGNAL 4
void Dtk::Power::UPowerDeviceInterface::EnergyRateChanged(const double _t1)
{
    QMetaObject::activate<void>(this, &staticMetaObject, 4, nullptr, _t1);
}

// SIGNAL 5
void Dtk::Power::UPowerDeviceInterface::EnergyChanged(const double _t1)
{
    QMetaObject::activate<void>(this, &staticMetaObject, 5, nullptr, _t1);
}

// SIGNAL 6
void Dtk::Power::UPowerDeviceInterface::IconNameChanged(const QString & _t1)
{
    QMetaObject::activate<void>(this, &staticMetaObject, 6, nullptr, _t1);
}
QT_WARNING_POP
