/****************************************************************************
**
** Copyright (C) 2016 The Qt Company Ltd.
** Contact: https://www.qt.io/licensing/
**
** This file is part of Qt for Python.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
** Licensees holding valid commercial Qt licenses may use this file in
** accordance with the commercial license agreement provided with the
** Software or, alternatively, in accordance with the terms contained in
** a written agreement between you and The Qt Company. For licensing terms
** and conditions see https://www.qt.io/terms-conditions. For further
** information use the contact form at https://www.qt.io/contact-us.
**
** GNU Lesser General Public License Usage
** Alternatively, this file may be used under the terms of the GNU Lesser
** General Public License version 3 as published by the Free Software
** Foundation and appearing in the file LICENSE.LGPL3 included in the
** packaging of this file. Please review the following information to
** ensure the GNU Lesser General Public License version 3 requirements
** will be met: https://www.gnu.org/licenses/lgpl-3.0.html.
**
** GNU General Public License Usage
** Alternatively, this file may be used under the terms of the GNU
** General Public License version 2.0 or (at your option) the GNU General
** Public license version 3 or any later version approved by the KDE Free
** Qt Foundation. The licenses are as published by the Free Software
** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3
** included in the packaging of this file. Please review the following
** information to ensure the GNU General Public License requirements will
** be met: https://www.gnu.org/licenses/gpl-2.0.html and
** https://www.gnu.org/licenses/gpl-3.0.html.
**
** $QT_END_LICENSE$
**
****************************************************************************/

//workaround to access protected functions
#define protected public

// default includes
#include <shiboken.h>
#ifndef QT_NO_VERSION_TAGGING
#  define QT_NO_VERSION_TAGGING
#endif
#include <QDebug>
#include <pysidesignal.h>
#include <pysideproperty.h>
#include <pyside.h>
#include <pysideqenum.h>
#include <feature_select.h>
QT_WARNING_DISABLE_DEPRECATED

#include <typeinfo>
#include <signalmanager.h>
#include <pysidemetafunction.h>
#include <iterator>

// module include
#include "pyside6_qtqml_python.h"

// main header
#include "qqmlengine_wrapper.h"

// inner classes

#include <cctype>
#include <cstring>



template <class T>
static const char *typeNameOf(const T &t)
{
    const char *typeName =  typeid(t).name();
    auto size = std::strlen(typeName);
#if defined(Q_CC_MSVC) // MSVC: "class QPaintDevice * __ptr64"
    if (auto lastStar = strchr(typeName, '*')) {
        // MSVC: "class QPaintDevice * __ptr64"
        while (*--lastStar == ' ') {
        }
        size = lastStar - typeName + 1;
    }
#else // g++, Clang: "QPaintDevice *" -> "P12QPaintDevice"
    if (size > 2 && typeName[0] == 'P' && std::isdigit(typeName[1])) {
        ++typeName;
        --size;
    }
#endif
    char *result = new char[size + 1];
    result[size] = '\0';
    memcpy(result, typeName, size);
    return result;
}

// Native ---------------------------------------------------------

void QQmlEngineWrapper::resetPyMethodCache()
{
    std::fill_n(m_PyMethodCache, sizeof(m_PyMethodCache) / sizeof(m_PyMethodCache[0]), false);
}

QQmlEngineWrapper::QQmlEngineWrapper(QObject * p) : QQmlEngine(p)
{
    resetPyMethodCache();
    // ... middle
}

void QQmlEngineWrapper::childEvent(QChildEvent * event)
{
    if (m_PyMethodCache[0]) {
        return this->::QObject::childEvent(event);
    }
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "childEvent";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[0] = true;
        return this->::QObject::childEvent(event);
    }

    Shiboken::AutoDecRef pyArgs(Py_BuildValue("(N)",
        Shiboken::Conversions::pointerToPython(SbkPySide6_QtCoreTypes[SBK_QCHILDEVENT_IDX], event)
    ));
    bool invalidateArg1 = PyTuple_GET_ITEM(pyArgs, 0)->ob_refcnt == 1;

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (invalidateArg1)
        Shiboken::Object::invalidate(PyTuple_GET_ITEM(pyArgs, 0));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return;
    }
}

void QQmlEngineWrapper::connectNotify(const QMetaMethod & signal)
{
    if (m_PyMethodCache[1]) {
        return this->::QObject::connectNotify(signal);
    }
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "connectNotify";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[1] = true;
        return this->::QObject::connectNotify(signal);
    }

    Shiboken::AutoDecRef pyArgs(Py_BuildValue("(N)",
        Shiboken::Conversions::copyToPython(SbkPySide6_QtCoreTypes[SBK_QMETAMETHOD_IDX], &signal)
    ));

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return;
    }
}

void QQmlEngineWrapper::customEvent(QEvent * event)
{
    if (m_PyMethodCache[2]) {
        return this->::QObject::customEvent(event);
    }
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "customEvent";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[2] = true;
        return this->::QObject::customEvent(event);
    }

    Shiboken::AutoDecRef pyArgs(Py_BuildValue("(N)",
        Shiboken::Conversions::pointerToPython(SbkPySide6_QtCoreTypes[SBK_QEVENT_IDX], event)
    ));
    bool invalidateArg1 = PyTuple_GET_ITEM(pyArgs, 0)->ob_refcnt == 1;

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (invalidateArg1)
        Shiboken::Object::invalidate(PyTuple_GET_ITEM(pyArgs, 0));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return;
    }
}

void QQmlEngineWrapper::disconnectNotify(const QMetaMethod & signal)
{
    if (m_PyMethodCache[3]) {
        return this->::QObject::disconnectNotify(signal);
    }
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "disconnectNotify";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[3] = true;
        return this->::QObject::disconnectNotify(signal);
    }

    Shiboken::AutoDecRef pyArgs(Py_BuildValue("(N)",
        Shiboken::Conversions::copyToPython(SbkPySide6_QtCoreTypes[SBK_QMETAMETHOD_IDX], &signal)
    ));

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return;
    }
}

bool QQmlEngineWrapper::event(QEvent * arg__1)
{
    if (m_PyMethodCache[4])
        return this->::QQmlEngine::event(arg__1);
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return false;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "event";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[4] = true;
        return this->::QQmlEngine::event(arg__1);
    }

    Shiboken::AutoDecRef pyArgs(Py_BuildValue("(N)",
        Shiboken::Conversions::pointerToPython(SbkPySide6_QtCoreTypes[SBK_QEVENT_IDX], arg__1)
    ));
    bool invalidateArg1 = PyTuple_GET_ITEM(pyArgs, 0)->ob_refcnt == 1;

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (invalidateArg1)
        Shiboken::Object::invalidate(PyTuple_GET_ITEM(pyArgs, 0));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return false;
    }
    // Check return type
    Shiboken::Conversions::PythonToCppConversion pythonToCpp =
        Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), pyResult);
    if (!pythonToCpp) {
        Shiboken::warning(PyExc_RuntimeWarning, 2,
            "Invalid return value in function %s, expected %s, got %s.",
            "QQmlEngine.event",
            "bool",
            Py_TYPE(pyResult)->tp_name);
        return false;
    }
    bool cppResult;
    pythonToCpp(pyResult, &cppResult);
    return cppResult;
}

bool QQmlEngineWrapper::eventFilter(QObject * watched, QEvent * event)
{
    if (m_PyMethodCache[5])
        return this->::QObject::eventFilter(watched, event);
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return false;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "eventFilter";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[5] = true;
        return this->::QObject::eventFilter(watched, event);
    }

    Shiboken::AutoDecRef pyArgs(Py_BuildValue("(NN)",
        Shiboken::Conversions::pointerToPython(SbkPySide6_QtCoreTypes[SBK_QOBJECT_IDX], watched),
        Shiboken::Conversions::pointerToPython(SbkPySide6_QtCoreTypes[SBK_QEVENT_IDX], event)
    ));
    bool invalidateArg2 = PyTuple_GET_ITEM(pyArgs, 1)->ob_refcnt == 1;

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (invalidateArg2)
        Shiboken::Object::invalidate(PyTuple_GET_ITEM(pyArgs, 1));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return false;
    }
    // Check return type
    Shiboken::Conversions::PythonToCppConversion pythonToCpp =
        Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), pyResult);
    if (!pythonToCpp) {
        Shiboken::warning(PyExc_RuntimeWarning, 2,
            "Invalid return value in function %s, expected %s, got %s.",
            "QQmlEngine.eventFilter",
            "bool",
            Py_TYPE(pyResult)->tp_name);
        return false;
    }
    bool cppResult;
    pythonToCpp(pyResult, &cppResult);
    return cppResult;
}

void QQmlEngineWrapper::timerEvent(QTimerEvent * event)
{
    if (m_PyMethodCache[7]) {
        return this->::QObject::timerEvent(event);
    }
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "timerEvent";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[7] = true;
        return this->::QObject::timerEvent(event);
    }

    Shiboken::AutoDecRef pyArgs(Py_BuildValue("(N)",
        Shiboken::Conversions::pointerToPython(SbkPySide6_QtCoreTypes[SBK_QTIMEREVENT_IDX], event)
    ));
    bool invalidateArg1 = PyTuple_GET_ITEM(pyArgs, 0)->ob_refcnt == 1;

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (invalidateArg1)
        Shiboken::Object::invalidate(PyTuple_GET_ITEM(pyArgs, 0));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return;
    }
}

const QMetaObject *QQmlEngineWrapper::metaObject() const
{
    if (QObject::d_ptr->metaObject)
        return QObject::d_ptr->dynamicMetaObject();
    SbkObject *pySelf = Shiboken::BindingManager::instance().retrieveWrapper(this);
    if (pySelf == nullptr)
        return QQmlEngine::metaObject();
    return PySide::SignalManager::retrieveMetaObject(reinterpret_cast<PyObject *>(pySelf));
}

int QQmlEngineWrapper::qt_metacall(QMetaObject::Call call, int id, void **args)
{
    int result = QQmlEngine::qt_metacall(call, id, args);
    return result < 0 ? result : PySide::SignalManager::qt_metacall(this, call, id, args);
}

void *QQmlEngineWrapper::qt_metacast(const char *_clname)
{
    if (!_clname)
        return {};
    SbkObject *pySelf = Shiboken::BindingManager::instance().retrieveWrapper(this);
    if (pySelf && PySide::inherits(Py_TYPE(pySelf), _clname))
        return static_cast<void *>(const_cast< QQmlEngineWrapper *>(this));
    return QQmlEngine::qt_metacast(_clname);
}

QQmlEngineWrapper::~QQmlEngineWrapper()
{
    SbkObject *wrapper = Shiboken::BindingManager::instance().retrieveWrapper(this);
    Shiboken::Object::destroy(wrapper, this);
}

// Target ---------------------------------------------------------

extern "C" {
static int
Sbk_QQmlEngine_Init(PyObject *self, PyObject *args, PyObject *kwds)
{
    const QMetaObject *metaObject;
    SbkObject *sbkSelf = reinterpret_cast<SbkObject *>(self);
    PySide::Feature::Select(self);
    if (Shiboken::Object::isUserType(self) && !Shiboken::ObjectType::canCallConstructor(self->ob_type, Shiboken::SbkType< ::QQmlEngine >()))
        return -1;

    ::QQmlEngineWrapper *cptr{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtQml.QQmlEngine.__init__";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp[1];
    SBK_UNUSED(pythonToCpp)
    const Py_ssize_t numArgs = PyTuple_GET_SIZE(args);
    SBK_UNUSED(numArgs)
    PyObject *pyArgs[] = {0};

    // invalid argument lengths


    if (!PyArg_ParseTuple(args, "|O:QQmlEngine", &(pyArgs[0])))
        return -1;


    // Overloaded function decisor
    // 0: QQmlEngine::QQmlEngine(QObject*)
    if (numArgs == 0) {
        overloadId = 0; // QQmlEngine(QObject*)
    } else if (numArgs >= 1
        && (pythonToCpp[0] = Shiboken::Conversions::pythonToCppPointerConversion(SbkPySide6_QtCoreTypes[SBK_QOBJECT_IDX], (pyArgs[0])))) {
        overloadId = 0; // QQmlEngine(QObject*)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QQmlEngine_Init_TypeError;

    // Call function/method
    {
        if (kwds && PyDict_Size(kwds) > 0) {
            PyObject *value{};
            Shiboken::AutoDecRef kwds_dup(PyDict_Copy(kwds));
            static PyObject *const key_p = Shiboken::String::createStaticString("p");
            if (PyDict_Contains(kwds, key_p)) {
                value = PyDict_GetItem(kwds, key_p);
                if (value && pyArgs[0]) {
                    errInfo.reset(key_p);
                    Py_INCREF(errInfo.object());
                    goto Sbk_QQmlEngine_Init_TypeError;
                }
                if (value) {
                    pyArgs[0] = value;
                    if (!(pythonToCpp[0] = Shiboken::Conversions::pythonToCppPointerConversion(SbkPySide6_QtCoreTypes[SBK_QOBJECT_IDX], (pyArgs[0]))))
                        goto Sbk_QQmlEngine_Init_TypeError;
                }
                PyDict_DelItem(kwds_dup, key_p);
            }
            if (PyDict_Size(kwds_dup) > 0) {
                errInfo.reset(kwds_dup.release());
                // fall through to handle extra keyword signals and properties
            }
        }
        if (!Shiboken::Object::isValid(pyArgs[0]))
            return -1;
        ::QObject *cppArg0 = nullptr;
        if (pythonToCpp[0])
            pythonToCpp[0](pyArgs[0], &cppArg0);

        if (!PyErr_Occurred()) {
            // QQmlEngine(QObject*)
            void *addr = PySide::nextQObjectMemoryAddr();
            if (addr) {
                cptr = new (addr) ::QQmlEngineWrapper(cppArg0);
                PySide::setNextQObjectMemoryAddr(0);
            } else {
                cptr = new ::QQmlEngineWrapper(cppArg0);
            }

        }
    }

    if (PyErr_Occurred() || !Shiboken::Object::setCppPointer(sbkSelf, Shiboken::SbkType< ::QQmlEngine >(), cptr)) {
        delete cptr;
        return -1;
    }
    if (!cptr) goto Sbk_QQmlEngine_Init_TypeError;

    Shiboken::Object::setValidCpp(sbkSelf, true);
    Shiboken::Object::setHasCppWrapper(sbkSelf, true);
    if (Shiboken::BindingManager::instance().hasWrapper(cptr)) {
        Shiboken::BindingManager::instance().releaseWrapper(Shiboken::BindingManager::instance().retrieveWrapper(cptr));
    }
    Shiboken::BindingManager::instance().registerWrapper(sbkSelf, cptr);

    // QObject setup
    PySide::Signal::updateSourceObject(self);
    metaObject = cptr->metaObject(); // <- init python qt properties
    if (!errInfo.isNull() && PyDict_Check(errInfo.object())) {
        if (!PySide::fillQtProperties(self, metaObject, errInfo))
            goto Sbk_QQmlEngine_Init_TypeError;
    };


    return 1;

    Sbk_QQmlEngine_Init_TypeError:
        Shiboken::setErrorAboutWrongArguments(args, fullName, errInfo);
        return -1;
}

static PyObject *Sbk_QQmlEngineFunc_addImageProvider(PyObject *self, PyObject *args)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QQmlEngine *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtQmlTypes[SBK_QQMLENGINE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtQml.QQmlEngine.addImageProvider";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp[2];
    SBK_UNUSED(pythonToCpp)
    const Py_ssize_t numArgs = PyTuple_GET_SIZE(args);
    SBK_UNUSED(numArgs)
    PyObject *pyArgs[] = {0, 0};

    // invalid argument lengths


    if (!PyArg_UnpackTuple(args, "addImageProvider", 2, 2, &(pyArgs[0]), &(pyArgs[1])))
        return {};


    // Overloaded function decisor
    // 0: QQmlEngine::addImageProvider(QString,QQmlImageProviderBase*)
    if (numArgs == 2
        && (pythonToCpp[0] = Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtCoreTypeConverters[SBK_QSTRING_IDX], (pyArgs[0])))
        && (pythonToCpp[1] = Shiboken::Conversions::pythonToCppPointerConversion(SbkPySide6_QtQmlTypes[SBK_QQMLIMAGEPROVIDERBASE_IDX], (pyArgs[1])))) {
        overloadId = 0; // addImageProvider(QString,QQmlImageProviderBase*)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QQmlEngineFunc_addImageProvider_TypeError;

    // Call function/method
    {
        ::QString cppArg0;
        pythonToCpp[0](pyArgs[0], &cppArg0);
        if (!Shiboken::Object::isValid(pyArgs[1]))
            return {};
        ::QQmlImageProviderBase *cppArg1;
        pythonToCpp[1](pyArgs[1], &cppArg1);

        if (!PyErr_Occurred()) {
            // addImageProvider(QString,QQmlImageProviderBase*)
            cppSelf->addImageProvider(cppArg0, cppArg1);

            // Ownership transferences.
            Shiboken::Object::releaseOwnership(pyArgs[1]);
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;

    Sbk_QQmlEngineFunc_addImageProvider_TypeError:
        Shiboken::setErrorAboutWrongArguments(args, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QQmlEngineFunc_addImportPath(PyObject *self, PyObject *pyArg)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QQmlEngine *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtQmlTypes[SBK_QQMLENGINE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtQml.QQmlEngine.addImportPath";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp;
    SBK_UNUSED(pythonToCpp)

    // Overloaded function decisor
    // 0: QQmlEngine::addImportPath(PyPathLike)
    if (Shiboken::String::checkPath(pyArg)) {
        overloadId = 0; // addImportPath(QString)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QQmlEngineFunc_addImportPath_TypeError;

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // addImportPath(QString)
            // Begin code injection
            // ========================================================================
            // START of custom code block [file: ../glue/qtcore.cpp (qfile-path-1)]
            auto cppArg0 = PySide::pyPathToQString(pyArg);
            // END of custom code block [file: ../glue/qtcore.cpp (qfile-path-1)]
            // ========================================================================
            // End of code injection

            cppSelf->addImportPath(cppArg0);
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;

    Sbk_QQmlEngineFunc_addImportPath_TypeError:
        Shiboken::setErrorAboutWrongArguments(pyArg, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QQmlEngineFunc_addNamedBundle(PyObject *self, PyObject *args)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QQmlEngine *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtQmlTypes[SBK_QQMLENGINE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtQml.QQmlEngine.addNamedBundle";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp[2];
    SBK_UNUSED(pythonToCpp)
    const Py_ssize_t numArgs = PyTuple_GET_SIZE(args);
    SBK_UNUSED(numArgs)
    PyObject *pyArgs[] = {0, 0};

    // invalid argument lengths


    if (!PyArg_UnpackTuple(args, "addNamedBundle", 2, 2, &(pyArgs[0]), &(pyArgs[1])))
        return {};


    // Overloaded function decisor
    // 0: QQmlEngine::addNamedBundle(QString,QString)->bool
    if (numArgs == 2
        && (pythonToCpp[0] = Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtCoreTypeConverters[SBK_QSTRING_IDX], (pyArgs[0])))
        && (pythonToCpp[1] = Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtCoreTypeConverters[SBK_QSTRING_IDX], (pyArgs[1])))) {
        overloadId = 0; // addNamedBundle(QString,QString)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QQmlEngineFunc_addNamedBundle_TypeError;

    // Call function/method
    {
        ::QString cppArg0;
        pythonToCpp[0](pyArgs[0], &cppArg0);
        ::QString cppArg1;
        pythonToCpp[1](pyArgs[1], &cppArg1);

        if (!PyErr_Occurred()) {
            // addNamedBundle(QString,QString)
            bool cppResult = cppSelf->addNamedBundle(cppArg0, cppArg1);
            pyResult = Shiboken::Conversions::copyToPython(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;

    Sbk_QQmlEngineFunc_addNamedBundle_TypeError:
        Shiboken::setErrorAboutWrongArguments(args, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QQmlEngineFunc_addPluginPath(PyObject *self, PyObject *pyArg)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QQmlEngine *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtQmlTypes[SBK_QQMLENGINE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtQml.QQmlEngine.addPluginPath";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp;
    SBK_UNUSED(pythonToCpp)

    // Overloaded function decisor
    // 0: QQmlEngine::addPluginPath(PyPathLike)
    if (Shiboken::String::checkPath(pyArg)) {
        overloadId = 0; // addPluginPath(QString)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QQmlEngineFunc_addPluginPath_TypeError;

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // addPluginPath(QString)
            // Begin code injection
            // ========================================================================
            // START of custom code block [file: ../glue/qtcore.cpp (qfile-path-1)]
            auto cppArg0 = PySide::pyPathToQString(pyArg);
            // END of custom code block [file: ../glue/qtcore.cpp (qfile-path-1)]
            // ========================================================================
            // End of code injection

            cppSelf->addPluginPath(cppArg0);
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;

    Sbk_QQmlEngineFunc_addPluginPath_TypeError:
        Shiboken::setErrorAboutWrongArguments(pyArg, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QQmlEngineFunc_addUrlInterceptor(PyObject *self, PyObject *pyArg)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QQmlEngine *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtQmlTypes[SBK_QQMLENGINE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtQml.QQmlEngine.addUrlInterceptor";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp;
    SBK_UNUSED(pythonToCpp)

    // Overloaded function decisor
    // 0: QQmlEngine::addUrlInterceptor(QQmlAbstractUrlInterceptor*)
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppPointerConversion(SbkPySide6_QtQmlTypes[SBK_QQMLABSTRACTURLINTERCEPTOR_IDX], (pyArg)))) {
        overloadId = 0; // addUrlInterceptor(QQmlAbstractUrlInterceptor*)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QQmlEngineFunc_addUrlInterceptor_TypeError;

    // Call function/method
    {
        if (!Shiboken::Object::isValid(pyArg))
            return {};
        ::QQmlAbstractUrlInterceptor *cppArg0;
        pythonToCpp(pyArg, &cppArg0);

        if (!PyErr_Occurred()) {
            // addUrlInterceptor(QQmlAbstractUrlInterceptor*)
            cppSelf->addUrlInterceptor(cppArg0);
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;

    Sbk_QQmlEngineFunc_addUrlInterceptor_TypeError:
        Shiboken::setErrorAboutWrongArguments(pyArg, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QQmlEngineFunc_baseUrl(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QQmlEngine *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtQmlTypes[SBK_QQMLENGINE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtQml.QQmlEngine.baseUrl";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // baseUrl()const
            QUrl cppResult = const_cast<const ::QQmlEngine *>(cppSelf)->baseUrl();
            pyResult = Shiboken::Conversions::copyToPython(SbkPySide6_QtCoreTypes[SBK_QURL_IDX], &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_QQmlEngineFunc_captureProperty(PyObject *self, PyObject *args)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QQmlEngine *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtQmlTypes[SBK_QQMLENGINE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtQml.QQmlEngine.captureProperty";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp[2];
    SBK_UNUSED(pythonToCpp)
    const Py_ssize_t numArgs = PyTuple_GET_SIZE(args);
    SBK_UNUSED(numArgs)
    PyObject *pyArgs[] = {0, 0};

    // invalid argument lengths


    if (!PyArg_UnpackTuple(args, "captureProperty", 2, 2, &(pyArgs[0]), &(pyArgs[1])))
        return {};


    // Overloaded function decisor
    // 0: QQmlEngine::captureProperty(QObject*,QMetaProperty)const
    if (numArgs == 2
        && (pythonToCpp[0] = Shiboken::Conversions::pythonToCppPointerConversion(SbkPySide6_QtCoreTypes[SBK_QOBJECT_IDX], (pyArgs[0])))
        && (pythonToCpp[1] = Shiboken::Conversions::pythonToCppReferenceConversion(SbkPySide6_QtCoreTypes[SBK_QMETAPROPERTY_IDX], (pyArgs[1])))) {
        overloadId = 0; // captureProperty(QObject*,QMetaProperty)const
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QQmlEngineFunc_captureProperty_TypeError;

    // Call function/method
    {
        if (!Shiboken::Object::isValid(pyArgs[0]))
            return {};
        ::QObject *cppArg0;
        pythonToCpp[0](pyArgs[0], &cppArg0);
        if (!Shiboken::Object::isValid(pyArgs[1]))
            return {};
        ::QMetaProperty cppArg1_local;
        ::QMetaProperty *cppArg1 = &cppArg1_local;
        if (pythonToCpp[1].isValue())
            pythonToCpp[1](pyArgs[1], &cppArg1_local);
        else
            pythonToCpp[1](pyArgs[1], &cppArg1);


        if (!PyErr_Occurred()) {
            // captureProperty(QObject*,QMetaProperty)const
            const_cast<const ::QQmlEngine *>(cppSelf)->captureProperty(cppArg0, *cppArg1);
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;

    Sbk_QQmlEngineFunc_captureProperty_TypeError:
        Shiboken::setErrorAboutWrongArguments(args, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QQmlEngineFunc_clearComponentCache(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QQmlEngine *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtQmlTypes[SBK_QQMLENGINE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtQml.QQmlEngine.clearComponentCache";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // clearComponentCache()
            cppSelf->clearComponentCache();
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;
}

static PyObject *Sbk_QQmlEngineFunc_contextForObject(PyObject *self, PyObject *pyArg)
{
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtQml.QQmlEngine.contextForObject";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp;
    SBK_UNUSED(pythonToCpp)

    // Overloaded function decisor
    // 0: static QQmlEngine::contextForObject(const QObject*)->QQmlContext*
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppPointerConversion(SbkPySide6_QtCoreTypes[SBK_QOBJECT_IDX], (pyArg)))) {
        overloadId = 0; // contextForObject(const QObject*)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QQmlEngineFunc_contextForObject_TypeError;

    // Call function/method
    {
        if (!Shiboken::Object::isValid(pyArg))
            return {};
        ::QObject *cppArg0;
        pythonToCpp(pyArg, &cppArg0);

        if (!PyErr_Occurred()) {
            // contextForObject(const QObject*)
            QQmlContext * cppResult = ::QQmlEngine::contextForObject(cppArg0);
            pyResult = Shiboken::Conversions::pointerToPython(SbkPySide6_QtQmlTypes[SBK_QQMLCONTEXT_IDX], cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;

    Sbk_QQmlEngineFunc_contextForObject_TypeError:
        Shiboken::setErrorAboutWrongArguments(pyArg, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QQmlEngineFunc_event(PyObject *self, PyObject *pyArg)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QQmlEngine *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtQmlTypes[SBK_QQMLENGINE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtQml.QQmlEngine.event";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp;
    SBK_UNUSED(pythonToCpp)

    // Overloaded function decisor
    // 0: QObject::event(QEvent*)->bool
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppPointerConversion(SbkPySide6_QtCoreTypes[SBK_QEVENT_IDX], (pyArg)))) {
        overloadId = 0; // event(QEvent*)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QQmlEngineFunc_event_TypeError;

    // Call function/method
    {
        if (!Shiboken::Object::isValid(pyArg))
            return {};
        ::QEvent *cppArg0;
        pythonToCpp(pyArg, &cppArg0);

        if (!PyErr_Occurred()) {
            // event(QEvent*)
            bool cppResult = Shiboken::Object::hasCppWrapper(reinterpret_cast<SbkObject *>(self))
                ? cppSelf->::QQmlEngine::event(cppArg0)
                : cppSelf->event(cppArg0);
            pyResult = Shiboken::Conversions::copyToPython(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;

    Sbk_QQmlEngineFunc_event_TypeError:
        Shiboken::setErrorAboutWrongArguments(pyArg, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QQmlEngineFunc_imageProvider(PyObject *self, PyObject *pyArg)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QQmlEngine *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtQmlTypes[SBK_QQMLENGINE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtQml.QQmlEngine.imageProvider";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp;
    SBK_UNUSED(pythonToCpp)

    // Overloaded function decisor
    // 0: QQmlEngine::imageProvider(QString)const->QQmlImageProviderBase*
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtCoreTypeConverters[SBK_QSTRING_IDX], (pyArg)))) {
        overloadId = 0; // imageProvider(QString)const
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QQmlEngineFunc_imageProvider_TypeError;

    // Call function/method
    {
        ::QString cppArg0;
        pythonToCpp(pyArg, &cppArg0);

        if (!PyErr_Occurred()) {
            // imageProvider(QString)const
            QQmlImageProviderBase * cppResult = const_cast<const ::QQmlEngine *>(cppSelf)->imageProvider(cppArg0);
            pyResult = Shiboken::Conversions::pointerToPython(SbkPySide6_QtQmlTypes[SBK_QQMLIMAGEPROVIDERBASE_IDX], cppResult);
            Shiboken::Object::setParent(self, pyResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;

    Sbk_QQmlEngineFunc_imageProvider_TypeError:
        Shiboken::setErrorAboutWrongArguments(pyArg, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QQmlEngineFunc_importPathList(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QQmlEngine *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtQmlTypes[SBK_QQMLENGINE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtQml.QQmlEngine.importPathList";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // importPathList()const
            QStringList cppResult = const_cast<const ::QQmlEngine *>(cppSelf)->importPathList();
            pyResult = Shiboken::Conversions::copyToPython(SbkPySide6_QtCoreTypeConverters[SBK_QSTRINGLIST_IDX], &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_QQmlEngineFunc_importPlugin(PyObject *self, PyObject *args)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QQmlEngine *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtQmlTypes[SBK_QQMLENGINE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtQml.QQmlEngine.importPlugin";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp[3];
    SBK_UNUSED(pythonToCpp)
    const Py_ssize_t numArgs = PyTuple_GET_SIZE(args);
    SBK_UNUSED(numArgs)
    PyObject *pyArgs[] = {0, 0, 0};

    // invalid argument lengths


    if (!PyArg_UnpackTuple(args, "importPlugin", 3, 3, &(pyArgs[0]), &(pyArgs[1]), &(pyArgs[2])))
        return {};


    // Overloaded function decisor
    // 0: QQmlEngine::importPlugin(QString,QString,QList<QQmlError>*)->bool
    if (numArgs == 3
        && (pythonToCpp[0] = Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtCoreTypeConverters[SBK_QSTRING_IDX], (pyArgs[0])))
        && (pythonToCpp[1] = Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtCoreTypeConverters[SBK_QSTRING_IDX], (pyArgs[1])))
        && (pythonToCpp[2] = Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtQmlTypeConverters[SBK_QTQML_QLIST_QQMLERROR_IDX], (pyArgs[2])))) {
        overloadId = 0; // importPlugin(QString,QString,QList<QQmlError>*)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QQmlEngineFunc_importPlugin_TypeError;

    // Call function/method
    {
        ::QString cppArg0;
        pythonToCpp[0](pyArgs[0], &cppArg0);
        ::QString cppArg1;
        pythonToCpp[1](pyArgs[1], &cppArg1);
        ::QList<QQmlError > *cppArg2;
        pythonToCpp[2](pyArgs[2], &cppArg2);

        if (!PyErr_Occurred()) {
            // importPlugin(QString,QString,QList<QQmlError>*)
            bool cppResult = cppSelf->importPlugin(cppArg0, cppArg1, cppArg2);
            pyResult = Shiboken::Conversions::copyToPython(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;

    Sbk_QQmlEngineFunc_importPlugin_TypeError:
        Shiboken::setErrorAboutWrongArguments(args, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QQmlEngineFunc_incubationController(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QQmlEngine *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtQmlTypes[SBK_QQMLENGINE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtQml.QQmlEngine.incubationController";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // incubationController()const
            QQmlIncubationController * cppResult = const_cast<const ::QQmlEngine *>(cppSelf)->incubationController();
            pyResult = Shiboken::Conversions::pointerToPython(SbkPySide6_QtQmlTypes[SBK_QQMLINCUBATIONCONTROLLER_IDX], cppResult);
            Shiboken::Object::setParent(self, pyResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_QQmlEngineFunc_interceptUrl(PyObject *self, PyObject *args)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QQmlEngine *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtQmlTypes[SBK_QQMLENGINE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtQml.QQmlEngine.interceptUrl";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp[2];
    SBK_UNUSED(pythonToCpp)
    const Py_ssize_t numArgs = PyTuple_GET_SIZE(args);
    SBK_UNUSED(numArgs)
    PyObject *pyArgs[] = {0, 0};

    // invalid argument lengths


    if (!PyArg_UnpackTuple(args, "interceptUrl", 2, 2, &(pyArgs[0]), &(pyArgs[1])))
        return {};


    // Overloaded function decisor
    // 0: QQmlEngine::interceptUrl(QUrl,QQmlAbstractUrlInterceptor::DataType)const->QUrl
    if (numArgs == 2
        && (pythonToCpp[0] = Shiboken::Conversions::pythonToCppReferenceConversion(SbkPySide6_QtCoreTypes[SBK_QURL_IDX], (pyArgs[0])))
        && (pythonToCpp[1] = Shiboken::Conversions::pythonToCppConversion(PepType_SETP(reinterpret_cast<SbkEnumType *>(SbkPySide6_QtQmlTypes[SBK_QQMLABSTRACTURLINTERCEPTOR_DATATYPE_IDX]))->converter, (pyArgs[1])))) {
        overloadId = 0; // interceptUrl(QUrl,QQmlAbstractUrlInterceptor::DataType)const
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QQmlEngineFunc_interceptUrl_TypeError;

    // Call function/method
    {
        if (!Shiboken::Object::isValid(pyArgs[0]))
            return {};
        ::QUrl cppArg0_local;
        ::QUrl *cppArg0 = &cppArg0_local;
        if (pythonToCpp[0].isValue())
            pythonToCpp[0](pyArgs[0], &cppArg0_local);
        else
            pythonToCpp[0](pyArgs[0], &cppArg0);

        ::QQmlAbstractUrlInterceptor::DataType cppArg1{QQmlAbstractUrlInterceptor::QmlFile};
        pythonToCpp[1](pyArgs[1], &cppArg1);

        if (!PyErr_Occurred()) {
            // interceptUrl(QUrl,QQmlAbstractUrlInterceptor::DataType)const
            QUrl cppResult = const_cast<const ::QQmlEngine *>(cppSelf)->interceptUrl(*cppArg0, cppArg1);
            pyResult = Shiboken::Conversions::copyToPython(SbkPySide6_QtCoreTypes[SBK_QURL_IDX], &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;

    Sbk_QQmlEngineFunc_interceptUrl_TypeError:
        Shiboken::setErrorAboutWrongArguments(args, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QQmlEngineFunc_networkAccessManager(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QQmlEngine *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtQmlTypes[SBK_QQMLENGINE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtQml.QQmlEngine.networkAccessManager";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // networkAccessManager()const
            QNetworkAccessManager * cppResult = const_cast<const ::QQmlEngine *>(cppSelf)->networkAccessManager();
            pyResult = Shiboken::Conversions::pointerToPython(SbkPySide6_QtNetworkTypes[SBK_QNETWORKACCESSMANAGER_IDX], cppResult);
            Shiboken::Object::setParent(self, pyResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_QQmlEngineFunc_networkAccessManagerFactory(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QQmlEngine *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtQmlTypes[SBK_QQMLENGINE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtQml.QQmlEngine.networkAccessManagerFactory";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // networkAccessManagerFactory()const
            QQmlNetworkAccessManagerFactory * cppResult = const_cast<const ::QQmlEngine *>(cppSelf)->networkAccessManagerFactory();
            pyResult = Shiboken::Conversions::pointerToPython(SbkPySide6_QtQmlTypes[SBK_QQMLNETWORKACCESSMANAGERFACTORY_IDX], cppResult);
            Shiboken::Object::setParent(self, pyResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_QQmlEngineFunc_offlineStorageDatabaseFilePath(PyObject *self, PyObject *pyArg)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QQmlEngine *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtQmlTypes[SBK_QQMLENGINE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtQml.QQmlEngine.offlineStorageDatabaseFilePath";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp;
    SBK_UNUSED(pythonToCpp)

    // Overloaded function decisor
    // 0: QQmlEngine::offlineStorageDatabaseFilePath(QString)const->QString
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtCoreTypeConverters[SBK_QSTRING_IDX], (pyArg)))) {
        overloadId = 0; // offlineStorageDatabaseFilePath(QString)const
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QQmlEngineFunc_offlineStorageDatabaseFilePath_TypeError;

    // Call function/method
    {
        ::QString cppArg0;
        pythonToCpp(pyArg, &cppArg0);

        if (!PyErr_Occurred()) {
            // offlineStorageDatabaseFilePath(QString)const
            QString cppResult = const_cast<const ::QQmlEngine *>(cppSelf)->offlineStorageDatabaseFilePath(cppArg0);
            pyResult = Shiboken::Conversions::copyToPython(SbkPySide6_QtCoreTypeConverters[SBK_QSTRING_IDX], &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;

    Sbk_QQmlEngineFunc_offlineStorageDatabaseFilePath_TypeError:
        Shiboken::setErrorAboutWrongArguments(pyArg, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QQmlEngineFunc_offlineStoragePath(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QQmlEngine *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtQmlTypes[SBK_QQMLENGINE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtQml.QQmlEngine.offlineStoragePath";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // offlineStoragePath()const
            QString cppResult = const_cast<const ::QQmlEngine *>(cppSelf)->offlineStoragePath();
            pyResult = Shiboken::Conversions::copyToPython(SbkPySide6_QtCoreTypeConverters[SBK_QSTRING_IDX], &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_QQmlEngineFunc_outputWarningsToStandardError(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QQmlEngine *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtQmlTypes[SBK_QQMLENGINE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtQml.QQmlEngine.outputWarningsToStandardError";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // outputWarningsToStandardError()const
            bool cppResult = const_cast<const ::QQmlEngine *>(cppSelf)->outputWarningsToStandardError();
            pyResult = Shiboken::Conversions::copyToPython(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_QQmlEngineFunc_pluginPathList(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QQmlEngine *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtQmlTypes[SBK_QQMLENGINE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtQml.QQmlEngine.pluginPathList";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // pluginPathList()const
            QStringList cppResult = const_cast<const ::QQmlEngine *>(cppSelf)->pluginPathList();
            pyResult = Shiboken::Conversions::copyToPython(SbkPySide6_QtCoreTypeConverters[SBK_QSTRINGLIST_IDX], &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_QQmlEngineFunc_removeImageProvider(PyObject *self, PyObject *pyArg)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QQmlEngine *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtQmlTypes[SBK_QQMLENGINE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtQml.QQmlEngine.removeImageProvider";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp;
    SBK_UNUSED(pythonToCpp)

    // Overloaded function decisor
    // 0: QQmlEngine::removeImageProvider(QString)
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtCoreTypeConverters[SBK_QSTRING_IDX], (pyArg)))) {
        overloadId = 0; // removeImageProvider(QString)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QQmlEngineFunc_removeImageProvider_TypeError;

    // Call function/method
    {
        ::QString cppArg0;
        pythonToCpp(pyArg, &cppArg0);

        if (!PyErr_Occurred()) {
            // removeImageProvider(QString)
            cppSelf->removeImageProvider(cppArg0);
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;

    Sbk_QQmlEngineFunc_removeImageProvider_TypeError:
        Shiboken::setErrorAboutWrongArguments(pyArg, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QQmlEngineFunc_removeUrlInterceptor(PyObject *self, PyObject *pyArg)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QQmlEngine *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtQmlTypes[SBK_QQMLENGINE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtQml.QQmlEngine.removeUrlInterceptor";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp;
    SBK_UNUSED(pythonToCpp)

    // Overloaded function decisor
    // 0: QQmlEngine::removeUrlInterceptor(QQmlAbstractUrlInterceptor*)
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppPointerConversion(SbkPySide6_QtQmlTypes[SBK_QQMLABSTRACTURLINTERCEPTOR_IDX], (pyArg)))) {
        overloadId = 0; // removeUrlInterceptor(QQmlAbstractUrlInterceptor*)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QQmlEngineFunc_removeUrlInterceptor_TypeError;

    // Call function/method
    {
        if (!Shiboken::Object::isValid(pyArg))
            return {};
        ::QQmlAbstractUrlInterceptor *cppArg0;
        pythonToCpp(pyArg, &cppArg0);

        if (!PyErr_Occurred()) {
            // removeUrlInterceptor(QQmlAbstractUrlInterceptor*)
            cppSelf->removeUrlInterceptor(cppArg0);
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;

    Sbk_QQmlEngineFunc_removeUrlInterceptor_TypeError:
        Shiboken::setErrorAboutWrongArguments(pyArg, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QQmlEngineFunc_retranslate(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QQmlEngine *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtQmlTypes[SBK_QQMLENGINE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtQml.QQmlEngine.retranslate";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // retranslate()
            cppSelf->retranslate();
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;
}

static PyObject *Sbk_QQmlEngineFunc_rootContext(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QQmlEngine *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtQmlTypes[SBK_QQMLENGINE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtQml.QQmlEngine.rootContext";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // rootContext()const
            QQmlContext * cppResult = const_cast<const ::QQmlEngine *>(cppSelf)->rootContext();
            pyResult = Shiboken::Conversions::pointerToPython(SbkPySide6_QtQmlTypes[SBK_QQMLCONTEXT_IDX], cppResult);
            Shiboken::Object::setParent(self, pyResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_QQmlEngineFunc_setBaseUrl(PyObject *self, PyObject *pyArg)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QQmlEngine *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtQmlTypes[SBK_QQMLENGINE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtQml.QQmlEngine.setBaseUrl";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp;
    SBK_UNUSED(pythonToCpp)

    // Overloaded function decisor
    // 0: QQmlEngine::setBaseUrl(QUrl)
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppReferenceConversion(SbkPySide6_QtCoreTypes[SBK_QURL_IDX], (pyArg)))) {
        overloadId = 0; // setBaseUrl(QUrl)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QQmlEngineFunc_setBaseUrl_TypeError;

    // Call function/method
    {
        if (!Shiboken::Object::isValid(pyArg))
            return {};
        ::QUrl cppArg0_local;
        ::QUrl *cppArg0 = &cppArg0_local;
        if (pythonToCpp.isValue())
            pythonToCpp(pyArg, &cppArg0_local);
        else
            pythonToCpp(pyArg, &cppArg0);


        if (!PyErr_Occurred()) {
            // setBaseUrl(QUrl)
            cppSelf->setBaseUrl(*cppArg0);
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;

    Sbk_QQmlEngineFunc_setBaseUrl_TypeError:
        Shiboken::setErrorAboutWrongArguments(pyArg, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QQmlEngineFunc_setContextForObject(PyObject *self, PyObject *args)
{
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtQml.QQmlEngine.setContextForObject";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp[2];
    SBK_UNUSED(pythonToCpp)
    const Py_ssize_t numArgs = PyTuple_GET_SIZE(args);
    SBK_UNUSED(numArgs)
    PyObject *pyArgs[] = {0, 0};

    // invalid argument lengths


    if (!PyArg_UnpackTuple(args, "setContextForObject", 2, 2, &(pyArgs[0]), &(pyArgs[1])))
        return {};


    // Overloaded function decisor
    // 0: static QQmlEngine::setContextForObject(QObject*,QQmlContext*)
    if (numArgs == 2
        && (pythonToCpp[0] = Shiboken::Conversions::pythonToCppPointerConversion(SbkPySide6_QtCoreTypes[SBK_QOBJECT_IDX], (pyArgs[0])))
        && (pythonToCpp[1] = Shiboken::Conversions::pythonToCppPointerConversion(SbkPySide6_QtQmlTypes[SBK_QQMLCONTEXT_IDX], (pyArgs[1])))) {
        overloadId = 0; // setContextForObject(QObject*,QQmlContext*)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QQmlEngineFunc_setContextForObject_TypeError;

    // Call function/method
    {
        if (!Shiboken::Object::isValid(pyArgs[0]))
            return {};
        ::QObject *cppArg0;
        pythonToCpp[0](pyArgs[0], &cppArg0);
        if (!Shiboken::Object::isValid(pyArgs[1]))
            return {};
        ::QQmlContext *cppArg1;
        pythonToCpp[1](pyArgs[1], &cppArg1);

        if (!PyErr_Occurred()) {
            // setContextForObject(QObject*,QQmlContext*)
            ::QQmlEngine::setContextForObject(cppArg0, cppArg1);
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;

    Sbk_QQmlEngineFunc_setContextForObject_TypeError:
        Shiboken::setErrorAboutWrongArguments(args, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QQmlEngineFunc_setImportPathList(PyObject *self, PyObject *pyArg)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QQmlEngine *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtQmlTypes[SBK_QQMLENGINE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtQml.QQmlEngine.setImportPathList";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp;
    SBK_UNUSED(pythonToCpp)

    // Overloaded function decisor
    // 0: QQmlEngine::setImportPathList(QStringList)
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtCoreTypeConverters[SBK_QSTRINGLIST_IDX], (pyArg)))) {
        overloadId = 0; // setImportPathList(QStringList)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QQmlEngineFunc_setImportPathList_TypeError;

    // Call function/method
    {
        ::QStringList cppArg0;
        pythonToCpp(pyArg, &cppArg0);

        if (!PyErr_Occurred()) {
            // setImportPathList(QStringList)
            cppSelf->setImportPathList(cppArg0);
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;

    Sbk_QQmlEngineFunc_setImportPathList_TypeError:
        Shiboken::setErrorAboutWrongArguments(pyArg, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QQmlEngineFunc_setIncubationController(PyObject *self, PyObject *pyArg)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QQmlEngine *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtQmlTypes[SBK_QQMLENGINE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtQml.QQmlEngine.setIncubationController";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp;
    SBK_UNUSED(pythonToCpp)

    // Overloaded function decisor
    // 0: QQmlEngine::setIncubationController(QQmlIncubationController*)
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppPointerConversion(SbkPySide6_QtQmlTypes[SBK_QQMLINCUBATIONCONTROLLER_IDX], (pyArg)))) {
        overloadId = 0; // setIncubationController(QQmlIncubationController*)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QQmlEngineFunc_setIncubationController_TypeError;

    // Call function/method
    {
        if (!Shiboken::Object::isValid(pyArg))
            return {};
        ::QQmlIncubationController *cppArg0;
        pythonToCpp(pyArg, &cppArg0);

        if (!PyErr_Occurred()) {
            // setIncubationController(QQmlIncubationController*)
            cppSelf->setIncubationController(cppArg0);
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;

    Sbk_QQmlEngineFunc_setIncubationController_TypeError:
        Shiboken::setErrorAboutWrongArguments(pyArg, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QQmlEngineFunc_setNetworkAccessManagerFactory(PyObject *self, PyObject *pyArg)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QQmlEngine *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtQmlTypes[SBK_QQMLENGINE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtQml.QQmlEngine.setNetworkAccessManagerFactory";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp;
    SBK_UNUSED(pythonToCpp)

    // Overloaded function decisor
    // 0: QQmlEngine::setNetworkAccessManagerFactory(QQmlNetworkAccessManagerFactory*)
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppPointerConversion(SbkPySide6_QtQmlTypes[SBK_QQMLNETWORKACCESSMANAGERFACTORY_IDX], (pyArg)))) {
        overloadId = 0; // setNetworkAccessManagerFactory(QQmlNetworkAccessManagerFactory*)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QQmlEngineFunc_setNetworkAccessManagerFactory_TypeError;

    // Call function/method
    {
        if (!Shiboken::Object::isValid(pyArg))
            return {};
        ::QQmlNetworkAccessManagerFactory *cppArg0;
        pythonToCpp(pyArg, &cppArg0);

        if (!PyErr_Occurred()) {
            // setNetworkAccessManagerFactory(QQmlNetworkAccessManagerFactory*)
            cppSelf->setNetworkAccessManagerFactory(cppArg0);
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;

    Sbk_QQmlEngineFunc_setNetworkAccessManagerFactory_TypeError:
        Shiboken::setErrorAboutWrongArguments(pyArg, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QQmlEngineFunc_setOfflineStoragePath(PyObject *self, PyObject *pyArg)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QQmlEngine *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtQmlTypes[SBK_QQMLENGINE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtQml.QQmlEngine.setOfflineStoragePath";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp;
    SBK_UNUSED(pythonToCpp)

    // Overloaded function decisor
    // 0: QQmlEngine::setOfflineStoragePath(QString)
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtCoreTypeConverters[SBK_QSTRING_IDX], (pyArg)))) {
        overloadId = 0; // setOfflineStoragePath(QString)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QQmlEngineFunc_setOfflineStoragePath_TypeError;

    // Call function/method
    {
        ::QString cppArg0;
        pythonToCpp(pyArg, &cppArg0);

        if (!PyErr_Occurred()) {
            // setOfflineStoragePath(QString)
            cppSelf->setOfflineStoragePath(cppArg0);
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;

    Sbk_QQmlEngineFunc_setOfflineStoragePath_TypeError:
        Shiboken::setErrorAboutWrongArguments(pyArg, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QQmlEngineFunc_setOutputWarningsToStandardError(PyObject *self, PyObject *pyArg)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QQmlEngine *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtQmlTypes[SBK_QQMLENGINE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtQml.QQmlEngine.setOutputWarningsToStandardError";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp;
    SBK_UNUSED(pythonToCpp)

    // Overloaded function decisor
    // 0: QQmlEngine::setOutputWarningsToStandardError(bool)
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), (pyArg)))) {
        overloadId = 0; // setOutputWarningsToStandardError(bool)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QQmlEngineFunc_setOutputWarningsToStandardError_TypeError;

    // Call function/method
    {
        bool cppArg0;
        pythonToCpp(pyArg, &cppArg0);

        if (!PyErr_Occurred()) {
            // setOutputWarningsToStandardError(bool)
            cppSelf->setOutputWarningsToStandardError(cppArg0);
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;

    Sbk_QQmlEngineFunc_setOutputWarningsToStandardError_TypeError:
        Shiboken::setErrorAboutWrongArguments(pyArg, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QQmlEngineFunc_setPluginPathList(PyObject *self, PyObject *pyArg)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QQmlEngine *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtQmlTypes[SBK_QQMLENGINE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtQml.QQmlEngine.setPluginPathList";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp;
    SBK_UNUSED(pythonToCpp)

    // Overloaded function decisor
    // 0: QQmlEngine::setPluginPathList(QStringList)
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppConversion(SbkPySide6_QtCoreTypeConverters[SBK_QSTRINGLIST_IDX], (pyArg)))) {
        overloadId = 0; // setPluginPathList(QStringList)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QQmlEngineFunc_setPluginPathList_TypeError;

    // Call function/method
    {
        ::QStringList cppArg0;
        pythonToCpp(pyArg, &cppArg0);

        if (!PyErr_Occurred()) {
            // setPluginPathList(QStringList)
            cppSelf->setPluginPathList(cppArg0);
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;

    Sbk_QQmlEngineFunc_setPluginPathList_TypeError:
        Shiboken::setErrorAboutWrongArguments(pyArg, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QQmlEngineFunc_setUrlInterceptor(PyObject *self, PyObject *pyArg)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QQmlEngine *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtQmlTypes[SBK_QQMLENGINE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtQml.QQmlEngine.setUrlInterceptor";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp;
    SBK_UNUSED(pythonToCpp)

    // Overloaded function decisor
    // 0: QQmlEngine::setUrlInterceptor(QQmlAbstractUrlInterceptor*)
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppPointerConversion(SbkPySide6_QtQmlTypes[SBK_QQMLABSTRACTURLINTERCEPTOR_IDX], (pyArg)))) {
        overloadId = 0; // setUrlInterceptor(QQmlAbstractUrlInterceptor*)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_QQmlEngineFunc_setUrlInterceptor_TypeError;

    // Call function/method
    {
        if (!Shiboken::Object::isValid(pyArg))
            return {};
        ::QQmlAbstractUrlInterceptor *cppArg0;
        pythonToCpp(pyArg, &cppArg0);

        if (!PyErr_Occurred()) {
            // setUrlInterceptor(QQmlAbstractUrlInterceptor*)
            cppSelf->setUrlInterceptor(cppArg0);
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;

    Sbk_QQmlEngineFunc_setUrlInterceptor_TypeError:
        Shiboken::setErrorAboutWrongArguments(pyArg, fullName, errInfo);
        return {};
}

static PyObject *Sbk_QQmlEngineFunc_trimComponentCache(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QQmlEngine *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtQmlTypes[SBK_QQMLENGINE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtQml.QQmlEngine.trimComponentCache";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // trimComponentCache()
            cppSelf->trimComponentCache();
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;
}

static PyObject *Sbk_QQmlEngineFunc_urlInterceptor(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QQmlEngine *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtQmlTypes[SBK_QQMLENGINE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtQml.QQmlEngine.urlInterceptor";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // urlInterceptor()const
            QQmlAbstractUrlInterceptor * cppResult = const_cast<const ::QQmlEngine *>(cppSelf)->urlInterceptor();
            pyResult = Shiboken::Conversions::pointerToPython(SbkPySide6_QtQmlTypes[SBK_QQMLABSTRACTURLINTERCEPTOR_IDX], cppResult);
            Shiboken::Object::setParent(self, pyResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_QQmlEngineFunc_urlInterceptors(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::QQmlEngine *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtQmlTypes[SBK_QQMLENGINE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtQml.QQmlEngine.urlInterceptors";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // urlInterceptors()const
            QList<QQmlAbstractUrlInterceptor* > cppResult = const_cast<const ::QQmlEngine *>(cppSelf)->urlInterceptors();
            pyResult = Shiboken::Conversions::copyToPython(SbkPySide6_QtQmlTypeConverters[SBK_QTQML_QLIST_QQMLABSTRACTURLINTERCEPTORPTR_IDX], &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}


static const char *Sbk_QQmlEngine_PropertyStrings[] = {
    "offlineStoragePath::",
    nullptr // Sentinel
};

static PyMethodDef Sbk_QQmlEngine_methods[] = {
    {"addImageProvider", reinterpret_cast<PyCFunction>(Sbk_QQmlEngineFunc_addImageProvider), METH_VARARGS},
    {"addImportPath", reinterpret_cast<PyCFunction>(Sbk_QQmlEngineFunc_addImportPath), METH_O},
    {"addNamedBundle", reinterpret_cast<PyCFunction>(Sbk_QQmlEngineFunc_addNamedBundle), METH_VARARGS},
    {"addPluginPath", reinterpret_cast<PyCFunction>(Sbk_QQmlEngineFunc_addPluginPath), METH_O},
    {"addUrlInterceptor", reinterpret_cast<PyCFunction>(Sbk_QQmlEngineFunc_addUrlInterceptor), METH_O},
    {"baseUrl", reinterpret_cast<PyCFunction>(Sbk_QQmlEngineFunc_baseUrl), METH_NOARGS},
    {"captureProperty", reinterpret_cast<PyCFunction>(Sbk_QQmlEngineFunc_captureProperty), METH_VARARGS},
    {"clearComponentCache", reinterpret_cast<PyCFunction>(Sbk_QQmlEngineFunc_clearComponentCache), METH_NOARGS},
    {"contextForObject", reinterpret_cast<PyCFunction>(Sbk_QQmlEngineFunc_contextForObject), METH_O|METH_STATIC},
    {"event", reinterpret_cast<PyCFunction>(Sbk_QQmlEngineFunc_event), METH_O},
    {"imageProvider", reinterpret_cast<PyCFunction>(Sbk_QQmlEngineFunc_imageProvider), METH_O},
    {"importPathList", reinterpret_cast<PyCFunction>(Sbk_QQmlEngineFunc_importPathList), METH_NOARGS},
    {"importPlugin", reinterpret_cast<PyCFunction>(Sbk_QQmlEngineFunc_importPlugin), METH_VARARGS},
    {"incubationController", reinterpret_cast<PyCFunction>(Sbk_QQmlEngineFunc_incubationController), METH_NOARGS},
    {"interceptUrl", reinterpret_cast<PyCFunction>(Sbk_QQmlEngineFunc_interceptUrl), METH_VARARGS},
    {"networkAccessManager", reinterpret_cast<PyCFunction>(Sbk_QQmlEngineFunc_networkAccessManager), METH_NOARGS},
    {"networkAccessManagerFactory", reinterpret_cast<PyCFunction>(Sbk_QQmlEngineFunc_networkAccessManagerFactory), METH_NOARGS},
    {"offlineStorageDatabaseFilePath", reinterpret_cast<PyCFunction>(Sbk_QQmlEngineFunc_offlineStorageDatabaseFilePath), METH_O},
    {"offlineStoragePath", reinterpret_cast<PyCFunction>(Sbk_QQmlEngineFunc_offlineStoragePath), METH_NOARGS},
    {"outputWarningsToStandardError", reinterpret_cast<PyCFunction>(Sbk_QQmlEngineFunc_outputWarningsToStandardError), METH_NOARGS},
    {"pluginPathList", reinterpret_cast<PyCFunction>(Sbk_QQmlEngineFunc_pluginPathList), METH_NOARGS},
    {"removeImageProvider", reinterpret_cast<PyCFunction>(Sbk_QQmlEngineFunc_removeImageProvider), METH_O},
    {"removeUrlInterceptor", reinterpret_cast<PyCFunction>(Sbk_QQmlEngineFunc_removeUrlInterceptor), METH_O},
    {"retranslate", reinterpret_cast<PyCFunction>(Sbk_QQmlEngineFunc_retranslate), METH_NOARGS},
    {"rootContext", reinterpret_cast<PyCFunction>(Sbk_QQmlEngineFunc_rootContext), METH_NOARGS},
    {"setBaseUrl", reinterpret_cast<PyCFunction>(Sbk_QQmlEngineFunc_setBaseUrl), METH_O},
    {"setContextForObject", reinterpret_cast<PyCFunction>(Sbk_QQmlEngineFunc_setContextForObject), METH_VARARGS|METH_STATIC},
    {"setImportPathList", reinterpret_cast<PyCFunction>(Sbk_QQmlEngineFunc_setImportPathList), METH_O},
    {"setIncubationController", reinterpret_cast<PyCFunction>(Sbk_QQmlEngineFunc_setIncubationController), METH_O},
    {"setNetworkAccessManagerFactory", reinterpret_cast<PyCFunction>(Sbk_QQmlEngineFunc_setNetworkAccessManagerFactory), METH_O},
    {"setOfflineStoragePath", reinterpret_cast<PyCFunction>(Sbk_QQmlEngineFunc_setOfflineStoragePath), METH_O},
    {"setOutputWarningsToStandardError", reinterpret_cast<PyCFunction>(Sbk_QQmlEngineFunc_setOutputWarningsToStandardError), METH_O},
    {"setPluginPathList", reinterpret_cast<PyCFunction>(Sbk_QQmlEngineFunc_setPluginPathList), METH_O},
    {"setUrlInterceptor", reinterpret_cast<PyCFunction>(Sbk_QQmlEngineFunc_setUrlInterceptor), METH_O},
    {"trimComponentCache", reinterpret_cast<PyCFunction>(Sbk_QQmlEngineFunc_trimComponentCache), METH_NOARGS},
    {"urlInterceptor", reinterpret_cast<PyCFunction>(Sbk_QQmlEngineFunc_urlInterceptor), METH_NOARGS},
    {"urlInterceptors", reinterpret_cast<PyCFunction>(Sbk_QQmlEngineFunc_urlInterceptors), METH_NOARGS},

    {nullptr, nullptr} // Sentinel
};

static int Sbk_QQmlEngine_setattro(PyObject *self, PyObject *name, PyObject *value)
{
    PySide::Feature::Select(self);
    if (value && PyCallable_Check(value)) {
        auto plain_inst = reinterpret_cast< ::QQmlEngine *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtQmlTypes[SBK_QQMLENGINE_IDX], reinterpret_cast<SbkObject *>(self)));
        auto inst = dynamic_cast<QQmlEngineWrapper *>(plain_inst);
        if (inst)
            inst->resetPyMethodCache();
    }
    Shiboken::AutoDecRef pp(reinterpret_cast<PyObject *>(PySide::Property::getObject(self, name)));
    if (!pp.isNull())
        return PySide::Property::setValue(reinterpret_cast<PySideProperty *>(pp.object()), self, value);
    return PyObject_GenericSetAttr(self, name, value);
}

} // extern "C"

static int Sbk_QQmlEngine_traverse(PyObject *self, visitproc visit, void *arg)
{
    return SbkObject_TypeF()->tp_traverse(self, visit, arg);
}
static int Sbk_QQmlEngine_clear(PyObject *self)
{
    return reinterpret_cast<PyTypeObject *>(SbkObject_TypeF())->tp_clear(self);
}
// Class Definition -----------------------------------------------
extern "C" {
static PyTypeObject *_Sbk_QQmlEngine_Type = nullptr;
static PyTypeObject *Sbk_QQmlEngine_TypeF(void)
{
    return _Sbk_QQmlEngine_Type;
}

static PyType_Slot Sbk_QQmlEngine_slots[] = {
    {Py_tp_base,        nullptr}, // inserted by introduceWrapperType
    {Py_tp_dealloc,     reinterpret_cast<void *>(&SbkDeallocWrapper)},
    {Py_tp_repr,        nullptr},
    {Py_tp_hash,        nullptr},
    {Py_tp_call,        nullptr},
    {Py_tp_str,         nullptr},
    {Py_tp_getattro,    nullptr},
    {Py_tp_setattro,    reinterpret_cast<void *>(Sbk_QQmlEngine_setattro)},
    {Py_tp_traverse,    reinterpret_cast<void *>(Sbk_QQmlEngine_traverse)},
    {Py_tp_clear,       reinterpret_cast<void *>(Sbk_QQmlEngine_clear)},
    {Py_tp_richcompare, nullptr},
    {Py_tp_iter,        nullptr},
    {Py_tp_iternext,    nullptr},
    {Py_tp_methods,     reinterpret_cast<void *>(Sbk_QQmlEngine_methods)},
    {Py_tp_getset,      nullptr},
    {Py_tp_init,        reinterpret_cast<void *>(Sbk_QQmlEngine_Init)},
    {Py_tp_new,         reinterpret_cast<void *>(SbkObjectTpNew)},
    {0, nullptr}
};
static PyType_Spec Sbk_QQmlEngine_spec = {
    "2:PySide6.QtQml.QQmlEngine",
    sizeof(SbkObject),
    0,
    Py_TPFLAGS_DEFAULT|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_GC,
    Sbk_QQmlEngine_slots
};

} //extern "C"

static void *Sbk_QQmlEngine_typeDiscovery(void *cptr, PyTypeObject *instanceType)
{
    if (instanceType == Shiboken::SbkType< ::QObject >())
        return dynamic_cast< ::QQmlEngine *>(reinterpret_cast< ::QObject *>(cptr));
    return {};
}


// Type conversion functions.

// Python to C++ pointer conversion - returns the C++ object of the Python wrapper (keeps object identity).
static void QQmlEngine_PythonToCpp_QQmlEngine_PTR(PyObject *pyIn, void *cppOut)
{
    Shiboken::Conversions::pythonToCppPointer(Sbk_QQmlEngine_TypeF(), pyIn, cppOut);
}
static PythonToCppFunc is_QQmlEngine_PythonToCpp_QQmlEngine_PTR_Convertible(PyObject *pyIn)
{
    if (pyIn == Py_None)
        return Shiboken::Conversions::nonePythonToCppNullPtr;
    if (PyObject_TypeCheck(pyIn, reinterpret_cast<PyTypeObject *>(Sbk_QQmlEngine_TypeF())))
        return QQmlEngine_PythonToCpp_QQmlEngine_PTR;
    return {};
}

// C++ to Python pointer conversion - tries to find the Python wrapper for the C++ object (keeps object identity).
static PyObject *QQmlEngine_PTR_CppToPython_QQmlEngine(const void *cppIn)
{
    return PySide::getWrapperForQObject(reinterpret_cast<::QQmlEngine *>(const_cast<void *>(cppIn)), Sbk_QQmlEngine_TypeF());

}

// The signatures string for the functions.
// Multiple signatures have their index "n:" in front.
static const char *QQmlEngine_SignatureStrings[] = {
    "PySide6.QtQml.QQmlEngine(self,p:PySide6.QtCore.QObject=nullptr)",
    "PySide6.QtQml.QQmlEngine.addImageProvider(self,id:QString,arg__2:PySide6.QtQml.QQmlImageProviderBase)",
    "PySide6.QtQml.QQmlEngine.addImportPath(self,dir:PyPathLike)",
    "PySide6.QtQml.QQmlEngine.addNamedBundle(self,arg__1:QString,arg__2:QString)->bool",
    "PySide6.QtQml.QQmlEngine.addPluginPath(self,dir:PyPathLike)",
    "PySide6.QtQml.QQmlEngine.addUrlInterceptor(self,urlInterceptor:PySide6.QtQml.QQmlAbstractUrlInterceptor)",
    "PySide6.QtQml.QQmlEngine.baseUrl(self)->PySide6.QtCore.QUrl",
    "PySide6.QtQml.QQmlEngine.captureProperty(self,object:PySide6.QtCore.QObject,property:PySide6.QtCore.QMetaProperty)",
    "PySide6.QtQml.QQmlEngine.clearComponentCache(self)",
    "PySide6.QtQml.QQmlEngine.contextForObject(arg__1:PySide6.QtCore.QObject)->PySide6.QtQml.QQmlContext",
    "PySide6.QtQml.QQmlEngine.event(self,arg__1:PySide6.QtCore.QEvent)->bool",
    "PySide6.QtQml.QQmlEngine.imageProvider(self,id:QString)->PySide6.QtQml.QQmlImageProviderBase",
    "PySide6.QtQml.QQmlEngine.importPathList(self)->QStringList",
    "PySide6.QtQml.QQmlEngine.importPlugin(self,filePath:QString,uri:QString,errors:QList[PySide6.QtQml.QQmlError])->bool",
    "PySide6.QtQml.QQmlEngine.incubationController(self)->PySide6.QtQml.QQmlIncubationController",
    "PySide6.QtQml.QQmlEngine.interceptUrl(self,url:typing.Union[PySide6.QtCore.QUrl, QString],type:PySide6.QtQml.QQmlAbstractUrlInterceptor.DataType)->PySide6.QtCore.QUrl",
    "PySide6.QtQml.QQmlEngine.networkAccessManager(self)->PySide6.QtNetwork.QNetworkAccessManager",
    "PySide6.QtQml.QQmlEngine.networkAccessManagerFactory(self)->PySide6.QtQml.QQmlNetworkAccessManagerFactory",
    "PySide6.QtQml.QQmlEngine.offlineStorageDatabaseFilePath(self,databaseName:QString)->QString",
    "PySide6.QtQml.QQmlEngine.offlineStoragePath(self)->QString",
    "PySide6.QtQml.QQmlEngine.outputWarningsToStandardError(self)->bool",
    "PySide6.QtQml.QQmlEngine.pluginPathList(self)->QStringList",
    "PySide6.QtQml.QQmlEngine.removeImageProvider(self,id:QString)",
    "PySide6.QtQml.QQmlEngine.removeUrlInterceptor(self,urlInterceptor:PySide6.QtQml.QQmlAbstractUrlInterceptor)",
    "PySide6.QtQml.QQmlEngine.retranslate(self)",
    "PySide6.QtQml.QQmlEngine.rootContext(self)->PySide6.QtQml.QQmlContext",
    "PySide6.QtQml.QQmlEngine.setBaseUrl(self,arg__1:typing.Union[PySide6.QtCore.QUrl, QString])",
    "PySide6.QtQml.QQmlEngine.setContextForObject(arg__1:PySide6.QtCore.QObject,arg__2:PySide6.QtQml.QQmlContext)",
    "PySide6.QtQml.QQmlEngine.setImportPathList(self,paths:QStringList)",
    "PySide6.QtQml.QQmlEngine.setIncubationController(self,arg__1:PySide6.QtQml.QQmlIncubationController)",
    "PySide6.QtQml.QQmlEngine.setNetworkAccessManagerFactory(self,arg__1:PySide6.QtQml.QQmlNetworkAccessManagerFactory)",
    "PySide6.QtQml.QQmlEngine.setOfflineStoragePath(self,dir:QString)",
    "PySide6.QtQml.QQmlEngine.setOutputWarningsToStandardError(self,arg__1:bool)",
    "PySide6.QtQml.QQmlEngine.setPluginPathList(self,paths:QStringList)",
    "PySide6.QtQml.QQmlEngine.setUrlInterceptor(self,urlInterceptor:PySide6.QtQml.QQmlAbstractUrlInterceptor)",
    "PySide6.QtQml.QQmlEngine.trimComponentCache(self)",
    "PySide6.QtQml.QQmlEngine.urlInterceptor(self)->PySide6.QtQml.QQmlAbstractUrlInterceptor",
    "PySide6.QtQml.QQmlEngine.urlInterceptors(self)->QList[PySide6.QtQml.QQmlAbstractUrlInterceptor]",
    nullptr}; // Sentinel

void init_QQmlEngine(PyObject *module)
{
    _Sbk_QQmlEngine_Type = Shiboken::ObjectType::introduceWrapperType(
        module,
        "QQmlEngine",
        "QQmlEngine*",
        &Sbk_QQmlEngine_spec,
        &Shiboken::callCppDestructor< ::QQmlEngine >,
        SbkPySide6_QtQmlTypes[SBK_QJSENGINE_IDX],
        0,
        0);
    auto *pyType = Sbk_QQmlEngine_TypeF(); // references _Sbk_QQmlEngine_Type
    InitSignatureStrings(pyType, QQmlEngine_SignatureStrings);
    SbkObjectType_SetPropertyStrings(reinterpret_cast<PyTypeObject *>(_Sbk_QQmlEngine_Type), Sbk_QQmlEngine_PropertyStrings);
    SbkPySide6_QtQmlTypes[SBK_QQMLENGINE_IDX]
        = Sbk_QQmlEngine_TypeF();

    // Register Converter
    SbkConverter *converter = Shiboken::Conversions::createConverter(Sbk_QQmlEngine_TypeF(),
        QQmlEngine_PythonToCpp_QQmlEngine_PTR,
        is_QQmlEngine_PythonToCpp_QQmlEngine_PTR_Convertible,
        QQmlEngine_PTR_CppToPython_QQmlEngine);

    Shiboken::Conversions::registerConverterName(converter, "QQmlEngine");
    Shiboken::Conversions::registerConverterName(converter, "QQmlEngine*");
    Shiboken::Conversions::registerConverterName(converter, "QQmlEngine&");
    Shiboken::Conversions::registerConverterName(converter, typeid(::QQmlEngine).name());
    Shiboken::Conversions::registerConverterName(converter, typeid(::QQmlEngineWrapper).name());


    Shiboken::ObjectType::setTypeDiscoveryFunctionV2(Sbk_QQmlEngine_TypeF(), &Sbk_QQmlEngine_typeDiscovery);

    PySide::Signal::registerSignals(Sbk_QQmlEngine_TypeF(), &::QQmlEngine::staticMetaObject);
    Shiboken::ObjectType::setSubTypeInitHook(Sbk_QQmlEngine_TypeF(), &PySide::initQObjectSubType);
    PySide::initDynamicMetaObject(Sbk_QQmlEngine_TypeF(), &::QQmlEngine::staticMetaObject, sizeof(QQmlEngineWrapper));
}
